From 5f8de423f190bbb79a62f804151bc24824fa32d8 Mon Sep 17 00:00:00 2001 From: "Matt A. Tobin" Date: Fri, 2 Feb 2018 04:16:08 -0500 Subject: Add m-esr52 at 52.6.0 --- testing/web-platform/tests/2dcontext/2x2.png | Bin 0 -> 788238 bytes .../tests/2dcontext/best-practices/.gitkeep | 0 .../tests/2dcontext/building-paths/.gitkeep | 0 .../canvas_complexshapes_arcto_001-ref.htm | 11 + .../canvas_complexshapes_arcto_001.htm | 26 + .../canvas_complexshapes_beziercurveto_001-ref.htm | 11 + .../canvas_complexshapes_beziercurveto_001.htm | 35 + .../web-platform/tests/2dcontext/clear-100x50.png | Bin 0 -> 117 bytes .../tests/2dcontext/compositing/.gitkeep | 0 .../compositing/2d.composite.canvas.copy.html | 38 + .../compositing/2d.composite.canvas.copy.png | Bin 0 -> 220 bytes .../2d.composite.canvas.destination-atop.html | 38 + .../2d.composite.canvas.destination-atop.png | Bin 0 -> 221 bytes .../2d.composite.canvas.destination-in.html | 38 + .../2d.composite.canvas.destination-in.png | Bin 0 -> 220 bytes .../2d.composite.canvas.destination-out.html | 38 + .../2d.composite.canvas.destination-out.png | Bin 0 -> 220 bytes .../2d.composite.canvas.destination-over.html | 38 + .../2d.composite.canvas.destination-over.png | Bin 0 -> 223 bytes .../compositing/2d.composite.canvas.lighter.html | 38 + .../compositing/2d.composite.canvas.lighter.png | Bin 0 -> 209 bytes .../2d.composite.canvas.source-atop.html | 38 + .../2d.composite.canvas.source-atop.png | Bin 0 -> 223 bytes .../compositing/2d.composite.canvas.source-in.html | 38 + .../compositing/2d.composite.canvas.source-in.png | Bin 0 -> 220 bytes .../2d.composite.canvas.source-out.html | 38 + .../compositing/2d.composite.canvas.source-out.png | Bin 0 -> 220 bytes .../2d.composite.canvas.source-over.html | 38 + .../2d.composite.canvas.source-over.png | Bin 0 -> 223 bytes .../compositing/2d.composite.canvas.xor.html | 38 + .../compositing/2d.composite.canvas.xor.png | Bin 0 -> 223 bytes .../compositing/2d.composite.clip.copy.html | 36 + .../2d.composite.clip.destination-atop.html | 36 + .../2d.composite.clip.destination-in.html | 36 + .../2d.composite.clip.destination-out.html | 36 + .../2d.composite.clip.destination-over.html | 36 + .../compositing/2d.composite.clip.lighter.html | 36 + .../compositing/2d.composite.clip.source-atop.html | 36 + .../compositing/2d.composite.clip.source-in.html | 36 + .../compositing/2d.composite.clip.source-out.html | 36 + .../compositing/2d.composite.clip.source-over.html | 36 + .../compositing/2d.composite.clip.xor.html | 36 + .../2d.composite.globalAlpha.canvas.html | 38 + .../2d.composite.globalAlpha.canvaspattern.html | 39 + .../2d.composite.globalAlpha.default.html | 27 + .../compositing/2d.composite.globalAlpha.fill.html | 32 + .../2d.composite.globalAlpha.image.html | 32 + .../2d.composite.globalAlpha.imagepattern.html | 33 + .../2d.composite.globalAlpha.invalid.html | 34 + .../2d.composite.globalAlpha.range.html | 36 + .../compositing/2d.composite.image.copy.html | 33 + .../compositing/2d.composite.image.copy.png | Bin 0 -> 220 bytes .../2d.composite.image.destination-atop.html | 33 + .../2d.composite.image.destination-atop.png | Bin 0 -> 221 bytes .../2d.composite.image.destination-in.html | 33 + .../2d.composite.image.destination-in.png | Bin 0 -> 220 bytes .../2d.composite.image.destination-out.html | 33 + .../2d.composite.image.destination-out.png | Bin 0 -> 220 bytes .../2d.composite.image.destination-over.html | 33 + .../2d.composite.image.destination-over.png | Bin 0 -> 223 bytes .../compositing/2d.composite.image.lighter.html | 33 + .../compositing/2d.composite.image.lighter.png | Bin 0 -> 209 bytes .../2d.composite.image.source-atop.html | 33 + .../compositing/2d.composite.image.source-atop.png | Bin 0 -> 223 bytes .../compositing/2d.composite.image.source-in.html | 33 + .../compositing/2d.composite.image.source-in.png | Bin 0 -> 220 bytes .../compositing/2d.composite.image.source-out.html | 33 + .../compositing/2d.composite.image.source-out.png | Bin 0 -> 220 bytes .../2d.composite.image.source-over.html | 33 + .../compositing/2d.composite.image.source-over.png | Bin 0 -> 223 bytes .../compositing/2d.composite.image.xor.html | 33 + .../compositing/2d.composite.image.xor.png | Bin 0 -> 223 bytes .../2d.composite.operation.casesensitive.html | 29 + .../compositing/2d.composite.operation.clear.html | 29 + .../compositing/2d.composite.operation.darker.html | 29 + .../2d.composite.operation.default.html | 27 + .../compositing/2d.composite.operation.get.html | 34 + .../2d.composite.operation.highlight.html | 29 + .../2d.composite.operation.nullsuffix.html | 29 + .../compositing/2d.composite.operation.over.html | 29 + .../2d.composite.operation.unrecognised.html | 29 + .../compositing/2d.composite.solid.copy.html | 33 + .../compositing/2d.composite.solid.copy.png | Bin 0 -> 205 bytes .../2d.composite.solid.destination-atop.html | 33 + .../2d.composite.solid.destination-atop.png | Bin 0 -> 206 bytes .../2d.composite.solid.destination-in.html | 33 + .../2d.composite.solid.destination-in.png | Bin 0 -> 206 bytes .../2d.composite.solid.destination-out.html | 33 + .../2d.composite.solid.destination-out.png | Bin 0 -> 117 bytes .../2d.composite.solid.destination-over.html | 33 + .../2d.composite.solid.destination-over.png | Bin 0 -> 206 bytes .../compositing/2d.composite.solid.lighter.html | 33 + .../compositing/2d.composite.solid.lighter.png | Bin 0 -> 207 bytes .../2d.composite.solid.source-atop.html | 33 + .../compositing/2d.composite.solid.source-atop.png | Bin 0 -> 205 bytes .../compositing/2d.composite.solid.source-in.html | 33 + .../compositing/2d.composite.solid.source-in.png | Bin 0 -> 205 bytes .../compositing/2d.composite.solid.source-out.html | 33 + .../compositing/2d.composite.solid.source-out.png | Bin 0 -> 117 bytes .../2d.composite.solid.source-over.html | 33 + .../compositing/2d.composite.solid.source-over.png | Bin 0 -> 205 bytes .../compositing/2d.composite.solid.xor.html | 33 + .../compositing/2d.composite.solid.xor.png | Bin 0 -> 117 bytes .../compositing/2d.composite.transparent.copy.html | 33 + .../compositing/2d.composite.transparent.copy.png | Bin 0 -> 221 bytes .../2d.composite.transparent.destination-atop.html | 33 + .../2d.composite.transparent.destination-atop.png | Bin 0 -> 220 bytes .../2d.composite.transparent.destination-in.html | 33 + .../2d.composite.transparent.destination-in.png | Bin 0 -> 221 bytes .../2d.composite.transparent.destination-out.html | 33 + .../2d.composite.transparent.destination-out.png | Bin 0 -> 221 bytes .../2d.composite.transparent.destination-over.html | 33 + .../2d.composite.transparent.destination-over.png | Bin 0 -> 222 bytes .../2d.composite.transparent.lighter.html | 33 + .../2d.composite.transparent.lighter.png | Bin 0 -> 208 bytes .../2d.composite.transparent.source-atop.html | 33 + .../2d.composite.transparent.source-atop.png | Bin 0 -> 222 bytes .../2d.composite.transparent.source-in.html | 33 + .../2d.composite.transparent.source-in.png | Bin 0 -> 221 bytes .../2d.composite.transparent.source-out.html | 33 + .../2d.composite.transparent.source-out.png | Bin 0 -> 221 bytes .../2d.composite.transparent.source-over.html | 33 + .../2d.composite.transparent.source-over.png | Bin 0 -> 223 bytes .../compositing/2d.composite.transparent.xor.html | 33 + .../compositing/2d.composite.transparent.xor.png | Bin 0 -> 222 bytes .../2d.composite.uncovered.fill.copy.html | 34 + .../2d.composite.uncovered.fill.copy.png | Bin 0 -> 117 bytes ....composite.uncovered.fill.destination-atop.html | 34 + ...d.composite.uncovered.fill.destination-atop.png | Bin 0 -> 117 bytes ...2d.composite.uncovered.fill.destination-in.html | 34 + .../2d.composite.uncovered.fill.destination-in.png | Bin 0 -> 117 bytes .../2d.composite.uncovered.fill.source-in.html | 34 + .../2d.composite.uncovered.fill.source-in.png | Bin 0 -> 117 bytes .../2d.composite.uncovered.fill.source-out.html | 34 + .../2d.composite.uncovered.fill.source-out.png | Bin 0 -> 117 bytes .../2d.composite.uncovered.image.copy.html | 34 + .../2d.composite.uncovered.image.copy.png | Bin 0 -> 117 bytes ...composite.uncovered.image.destination-atop.html | 34 + ....composite.uncovered.image.destination-atop.png | Bin 0 -> 117 bytes ...d.composite.uncovered.image.destination-in.html | 34 + ...2d.composite.uncovered.image.destination-in.png | Bin 0 -> 117 bytes .../2d.composite.uncovered.image.source-in.html | 34 + .../2d.composite.uncovered.image.source-in.png | Bin 0 -> 117 bytes .../2d.composite.uncovered.image.source-out.html | 34 + .../2d.composite.uncovered.image.source-out.png | Bin 0 -> 117 bytes .../2d.composite.uncovered.nocontext.copy.html | 33 + .../2d.composite.uncovered.nocontext.copy.png | Bin 0 -> 117 bytes ...osite.uncovered.nocontext.destination-atop.html | 33 + ...posite.uncovered.nocontext.destination-atop.png | Bin 0 -> 117 bytes ...mposite.uncovered.nocontext.destination-in.html | 33 + ...omposite.uncovered.nocontext.destination-in.png | Bin 0 -> 117 bytes ...2d.composite.uncovered.nocontext.source-in.html | 33 + .../2d.composite.uncovered.nocontext.source-in.png | Bin 0 -> 117 bytes ...d.composite.uncovered.nocontext.source-out.html | 33 + ...2d.composite.uncovered.nocontext.source-out.png | Bin 0 -> 117 bytes .../2d.composite.uncovered.pattern.copy.html | 34 + .../2d.composite.uncovered.pattern.copy.png | Bin 0 -> 117 bytes ...mposite.uncovered.pattern.destination-atop.html | 34 + ...omposite.uncovered.pattern.destination-atop.png | Bin 0 -> 117 bytes ...composite.uncovered.pattern.destination-in.html | 34 + ....composite.uncovered.pattern.destination-in.png | Bin 0 -> 117 bytes .../2d.composite.uncovered.pattern.source-in.html | 34 + .../2d.composite.uncovered.pattern.source-in.png | Bin 0 -> 117 bytes .../2d.composite.uncovered.pattern.source-out.html | 34 + .../2d.composite.uncovered.pattern.source-out.png | Bin 0 -> 117 bytes ...ompositing_globalcompositeoperation_001-ref.htm | 11 + ...as_compositing_globalcompositeoperation_001.htm | 32 + .../2dcontext/conformance-requirements/.gitkeep | 0 .../2d.coordinatespace-manual.html | 34 + .../2d.coordinatespace.png | Bin 0 -> 219 bytes .../conformance-requirements/2d.missingargs.html | 142 + .../conformance-requirements/2d.type.delete.html | 29 + .../conformance-requirements/2d.voidreturn.html | 63 + .../drawing-images-to-the-canvas/.gitkeep | 0 .../2d.drawImage.3arg.html | 38 + .../2d.drawImage.5arg.html | 39 + .../2d.drawImage.9arg.basic.html | 34 + .../2d.drawImage.9arg.destpos.html | 39 + .../2d.drawImage.9arg.destsize.html | 39 + .../2d.drawImage.9arg.sourcepos.html | 34 + .../2d.drawImage.9arg.sourcesize.html | 41 + .../2d.drawImage.alpha.html | 32 + .../2d.drawImage.animated.apng.html | 32 + .../2d.drawImage.animated.gif.html | 32 + .../2d.drawImage.animated.poster.html | 29 + .../2d.drawImage.broken.html | 32 + .../2d.drawImage.canvas.html | 40 + .../2d.drawImage.clip.html | 33 + .../2d.drawImage.composite.html | 32 + .../2d.drawImage.floatsource.html | 29 + .../2d.drawImage.incomplete.emptysrc.html | 33 + .../2d.drawImage.incomplete.immediate.html | 37 + .../2d.drawImage.incomplete.nosrc.html | 31 + .../2d.drawImage.incomplete.reload.html | 39 + .../2d.drawImage.incomplete.removedsrc.html | 33 + .../2d.drawImage.negativedest.html | 41 + .../2d.drawImage.negativedir.html | 41 + .../2d.drawImage.negativesource.html | 41 + .../2d.drawImage.nonfinite.html | 332 + .../2d.drawImage.nowrap.html | 33 + .../2d.drawImage.null.html | 27 + .../2d.drawImage.path.html | 32 + .../2d.drawImage.self.1.html | 36 + .../2d.drawImage.self.2.html | 38 + .../2d.drawImage.svg.html | 29 + .../2d.drawImage.transform.html | 32 + .../2d.drawImage.wrongtype.html | 30 + .../2d.drawImage.zerocanvas.html | 43 + .../2d.drawImage.zerosource.html | 33 + .../2d.drawImage.zerosource.image.html | 35 + .../drawimage_canvas_1.html | 34 + .../drawimage_canvas_10.html | 38 + .../drawimage_canvas_10_ref.html | 26 + .../drawimage_canvas_11.html | 36 + .../drawimage_canvas_11_ref.html | 26 + .../drawimage_canvas_12.html | 36 + .../drawimage_canvas_12_ref.html | 26 + .../drawimage_canvas_1_ref.html | 31 + .../drawimage_canvas_2.html | 35 + .../drawimage_canvas_2_ref.html | 31 + .../drawimage_canvas_3.html | 36 + .../drawimage_canvas_3_ref.html | 31 + .../drawimage_canvas_4.html | 37 + .../drawimage_canvas_4_ref.html | 26 + .../drawimage_canvas_5.html | 36 + .../drawimage_canvas_5_ref.html | 26 + .../drawimage_canvas_6.html | 36 + .../drawimage_canvas_6_ref.html | 26 + .../drawimage_canvas_7.html | 36 + .../drawimage_canvas_7_ref.html | 26 + .../drawimage_canvas_8.html | 36 + .../drawimage_canvas_8_ref.html | 26 + .../drawimage_canvas_9.html | 43 + .../drawimage_canvas_9_ref.html | 22 + .../drawimage_html_image_1.html | 30 + .../drawimage_html_image_10.html | 34 + .../drawimage_html_image_10_ref.html | 19 + .../drawimage_html_image_11.html | 32 + .../drawimage_html_image_11_ref.html | 19 + .../drawimage_html_image_12.html | 32 + .../drawimage_html_image_12_ref.html | 32 + .../drawimage_html_image_13.html | 38 + .../drawimage_html_image_13_ref.html | 20 + .../drawimage_html_image_1_ref.html | 19 + .../drawimage_html_image_2.html | 31 + .../drawimage_html_image_2_ref.html | 23 + .../drawimage_html_image_3.html | 31 + .../drawimage_html_image_3_ref.html | 23 + .../drawimage_html_image_4.html | 32 + .../drawimage_html_image_4_ref.html | 29 + .../drawimage_html_image_5.html | 31 + .../drawimage_html_image_5_ref.html | 39 + .../drawimage_html_image_6.html | 32 + .../drawimage_html_image_6_ref.html | 25 + .../drawimage_html_image_7.html | 32 + .../drawimage_html_image_7_ref.html | 35 + .../drawimage_html_image_8.html | 32 + .../drawimage_html_image_8_ref.html | 35 + .../drawimage_html_image_9.html | 37 + .../drawimage_html_image_9_ref.html | 19 + .../tests/2dcontext/drawing-model/.gitkeep | 0 .../2dcontext/drawing-paths-to-the-canvas/.gitkeep | 0 .../canvas_complexshapes_ispointInpath_001.htm | 31 + .../canvas_focus_drawCustomFocusRing_001.html | 41 + ...as_focus_drawFocusIfNeeded_AAPI_001-manual.html | 50 + .../drawFocusIfNeeded_001.html | 66 + .../drawFocusIfNeeded_002.html | 68 + .../drawFocusIfNeeded_003.html | 69 + .../drawFocusIfNeeded_004.html | 88 + .../drawFocusIfNeeded_005.html | 88 + .../drawing-rectangles-to-the-canvas/.gitkeep | 0 .../2d.clearRect.basic.html | 30 + .../2d.clearRect.clip.html | 39 + .../2d.clearRect.globalalpha.html | 31 + .../2d.clearRect.globalcomposite.html | 31 + .../2d.clearRect.negative.html | 36 + .../2d.clearRect.nonfinite.html | 54 + .../2d.clearRect.path.html | 32 + .../2d.clearRect.shadow.html | 34 + .../2d.clearRect.transform.html | 32 + .../2d.clearRect.zero.html | 32 + .../2d.fillRect.basic.html | 29 + .../2d.fillRect.clip.html | 40 + .../2d.fillRect.negative.html | 37 + .../2d.fillRect.nonfinite.html | 55 + .../2d.fillRect.path.html | 33 + .../2d.fillRect.shadow.html | 34 + .../2d.fillRect.transform.html | 31 + .../2d.fillRect.zero.html | 33 + .../2d.strokeRect.basic.html | 30 + .../2d.strokeRect.clip.html | 41 + .../2d.strokeRect.globalalpha.html | 31 + .../2d.strokeRect.globalcomposite.html | 31 + .../2d.strokeRect.negative.html | 38 + .../2d.strokeRect.nonfinite.html | 56 + .../2d.strokeRect.path.html | 34 + .../2d.strokeRect.shadow.html | 37 + .../2d.strokeRect.transform.html | 32 + .../2d.strokeRect.zero.1.html | 30 + .../2d.strokeRect.zero.2.html | 32 + .../2d.strokeRect.zero.3.html | 30 + .../2d.strokeRect.zero.4.html | 31 + .../2d.strokeRect.zero.5.html | 31 + .../clear-100x50.png | Bin 0 -> 117 bytes .../2dcontext/drawing-text-to-the-canvas/.gitkeep | 0 .../2d.text.draw.align.center.html | 48 + .../2d.text.draw.align.end.ltr.html | 48 + .../2d.text.draw.align.end.rtl.html | 48 + .../2d.text.draw.align.left.html | 48 + .../2d.text.draw.align.right.html | 48 + .../2d.text.draw.align.start.ltr.html | 48 + .../2d.text.draw.align.start.rtl.html | 48 + .../2d.text.draw.baseline.alphabetic.html | 48 + .../2d.text.draw.fill.basic-manual.html | 32 + .../2d.text.draw.fill.basic.png | Bin 0 -> 1062 bytes .../2d.text.draw.fill.maxWidth.NaN.html | 32 + .../2d.text.draw.fill.maxWidth.bound.html | 45 + .../2d.text.draw.fill.maxWidth.fontface.html | 45 + .../2d.text.draw.fill.maxWidth.large-manual.html | 31 + .../2d.text.draw.fill.maxWidth.large.png | Bin 0 -> 1062 bytes .../2d.text.draw.fill.maxWidth.negative.html | 32 + .../2d.text.draw.fill.maxWidth.small.html | 32 + .../2d.text.draw.fill.maxWidth.zero.html | 32 + .../2d.text.draw.fill.rtl-manual.html | 32 + .../2d.text.draw.fill.rtl.png | Bin 0 -> 1062 bytes .../2d.text.draw.fill.unaffected.html | 42 + .../2d.text.draw.fontface.html | 45 + .../2d.text.draw.fontface.notinpage.html | 44 + .../2d.text.draw.fontface.repeat.html | 45 + .../2d.text.draw.kern.consistent-manual.html | 36 + .../2d.text.draw.space.basic.html | 43 + .../2d.text.draw.space.collapse.nonspace.html | 43 + .../2d.text.draw.stroke.basic-manual.html | 33 + .../2d.text.draw.stroke.basic.png | Bin 0 -> 1637 bytes .../2d.text.draw.stroke.unaffected.html | 43 + .../2d.text.measure.width.basic.html | 43 + .../2d.text.measure.width.empty.html | 38 + .../tests/2dcontext/drawingstyle-objects/.gitkeep | 0 .../web-platform/tests/2dcontext/examples/.gitkeep | 0 .../2dcontext/fill-and-stroke-styles/.gitkeep | 0 .../2d.fillStyle.default.html | 27 + .../2d.fillStyle.get.semitransparent.html | 28 + .../2d.fillStyle.get.solid.html | 28 + .../2d.fillStyle.get.transparent.html | 28 + .../2d.fillStyle.invalidstring.html | 32 + .../2d.fillStyle.invalidtype.html | 32 + .../2d.fillStyle.parse.css-color-4-hsl-1.html | 31 + .../2d.fillStyle.parse.css-color-4-hsl-1.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.css-color-4-hsl-2.html | 31 + .../2d.fillStyle.parse.css-color-4-hsl-2.png | Bin 0 -> 221 bytes .../2d.fillStyle.parse.css-color-4-hsl-3.html | 31 + .../2d.fillStyle.parse.css-color-4-hsl-3.png | Bin 0 -> 221 bytes .../2d.fillStyle.parse.css-color-4-hsl-4.html | 31 + .../2d.fillStyle.parse.css-color-4-hsl-4.png | Bin 0 -> 221 bytes .../2d.fillStyle.parse.css-color-4-hsl-5.html | 31 + .../2d.fillStyle.parse.css-color-4-hsl-5.png | Bin 0 -> 221 bytes .../2d.fillStyle.parse.css-color-4-hsl-6.html | 31 + .../2d.fillStyle.parse.css-color-4-hsl-6.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.css-color-4-hsl-7.html | 31 + .../2d.fillStyle.parse.css-color-4-hsl-7.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.css-color-4-hsl-8.html | 31 + .../2d.fillStyle.parse.css-color-4-hsl-8.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.css-color-4-hsl-9.html | 31 + .../2d.fillStyle.parse.css-color-4-hsl-9.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.css-color-4-hsla-1.html | 31 + .../2d.fillStyle.parse.css-color-4-hsla-1.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.css-color-4-hsla-2.html | 31 + .../2d.fillStyle.parse.css-color-4-hsla-2.png | Bin 0 -> 221 bytes .../2d.fillStyle.parse.css-color-4-hsla-3.html | 31 + .../2d.fillStyle.parse.css-color-4-hsla-3.png | Bin 0 -> 221 bytes .../2d.fillStyle.parse.css-color-4-hsla-4.html | 31 + .../2d.fillStyle.parse.css-color-4-hsla-4.png | Bin 0 -> 221 bytes .../2d.fillStyle.parse.css-color-4-hsla-5.html | 31 + .../2d.fillStyle.parse.css-color-4-hsla-5.png | Bin 0 -> 221 bytes .../2d.fillStyle.parse.css-color-4-hsla-6.html | 31 + .../2d.fillStyle.parse.css-color-4-hsla-6.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.css-color-4-hsla-7.html | 31 + .../2d.fillStyle.parse.css-color-4-hsla-7.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.css-color-4-hsla-8.html | 31 + .../2d.fillStyle.parse.css-color-4-hsla-8.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.css-color-4-hsla-9.html | 31 + .../2d.fillStyle.parse.css-color-4-hsla-9.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.css-color-4-rgb-1.html | 31 + .../2d.fillStyle.parse.css-color-4-rgb-1.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.css-color-4-rgb-2.html | 31 + .../2d.fillStyle.parse.css-color-4-rgb-2.png | Bin 0 -> 221 bytes .../2d.fillStyle.parse.css-color-4-rgb-3.html | 31 + .../2d.fillStyle.parse.css-color-4-rgb-3.png | Bin 0 -> 221 bytes .../2d.fillStyle.parse.css-color-4-rgb-4.html | 31 + .../2d.fillStyle.parse.css-color-4-rgb-4.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.css-color-4-rgb-5.html | 31 + .../2d.fillStyle.parse.css-color-4-rgb-5.png | Bin 0 -> 221 bytes .../2d.fillStyle.parse.css-color-4-rgb-6.html | 31 + .../2d.fillStyle.parse.css-color-4-rgb-6.png | Bin 0 -> 221 bytes .../2d.fillStyle.parse.css-color-4-rgba-1.html | 31 + .../2d.fillStyle.parse.css-color-4-rgba-1.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.css-color-4-rgba-2.html | 31 + .../2d.fillStyle.parse.css-color-4-rgba-2.png | Bin 0 -> 221 bytes .../2d.fillStyle.parse.css-color-4-rgba-3.html | 31 + .../2d.fillStyle.parse.css-color-4-rgba-3.png | Bin 0 -> 221 bytes .../2d.fillStyle.parse.css-color-4-rgba-4.html | 31 + .../2d.fillStyle.parse.css-color-4-rgba-4.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.css-color-4-rgba-5.html | 31 + .../2d.fillStyle.parse.css-color-4-rgba-5.png | Bin 0 -> 221 bytes .../2d.fillStyle.parse.css-color-4-rgba-6.html | 31 + .../2d.fillStyle.parse.css-color-4-rgba-6.png | Bin 0 -> 221 bytes .../2d.fillStyle.parse.current.basic.html | 31 + .../2d.fillStyle.parse.current.changed.html | 32 + .../2d.fillStyle.parse.current.notrendered.html | 33 + .../2d.fillStyle.parse.current.removed.html | 43 + .../2d.fillStyle.parse.current.removed.png | Bin 0 -> 112 bytes .../2d.fillStyle.parse.hex3.html | 31 + .../2d.fillStyle.parse.hex3.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.hex4.html | 31 + .../2d.fillStyle.parse.hex4.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.hex6.html | 31 + .../2d.fillStyle.parse.hex6.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.hex8.html | 31 + .../2d.fillStyle.parse.hex8.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.hsl-1.html | 31 + .../2d.fillStyle.parse.hsl-1.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.hsl-2.html | 31 + .../2d.fillStyle.parse.hsl-2.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.hsl-3.html | 31 + .../2d.fillStyle.parse.hsl-3.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.hsl-4.html | 31 + .../2d.fillStyle.parse.hsl-4.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.hsl-5.html | 31 + .../2d.fillStyle.parse.hsl-5.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.hsl-6.html | 31 + .../2d.fillStyle.parse.hsl-6.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.hsl-clamp-1.html | 31 + .../2d.fillStyle.parse.hsl-clamp-1.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.hsl-clamp-2.html | 31 + .../2d.fillStyle.parse.hsl-clamp-2.png | Bin 0 -> 207 bytes .../2d.fillStyle.parse.hsl-clamp-3.html | 31 + .../2d.fillStyle.parse.hsl-clamp-3.png | Bin 0 -> 207 bytes .../2d.fillStyle.parse.hsl-clamp-4.html | 31 + .../2d.fillStyle.parse.hsl-clamp-4.png | Bin 0 -> 112 bytes .../2d.fillStyle.parse.hsla-1.html | 31 + .../2d.fillStyle.parse.hsla-1.png | Bin 0 -> 220 bytes .../2d.fillStyle.parse.hsla-2.html | 31 + .../2d.fillStyle.parse.hsla-2.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.hsla-clamp-1.html | 31 + .../2d.fillStyle.parse.hsla-clamp-1.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.hsla-clamp-2.html | 31 + .../2d.fillStyle.parse.hsla-clamp-2.png | Bin 0 -> 207 bytes .../2d.fillStyle.parse.hsla-clamp-3.html | 31 + .../2d.fillStyle.parse.hsla-clamp-3.png | Bin 0 -> 207 bytes .../2d.fillStyle.parse.hsla-clamp-4.html | 31 + .../2d.fillStyle.parse.hsla-clamp-4.png | Bin 0 -> 112 bytes .../2d.fillStyle.parse.hsla-clamp-5.html | 31 + .../2d.fillStyle.parse.hsla-clamp-5.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.hsla-clamp-6.html | 31 + .../2d.fillStyle.parse.hsla-clamp-6.png | Bin 0 -> 117 bytes .../2d.fillStyle.parse.html4.html | 31 + .../2d.fillStyle.parse.html4.png | Bin 0 -> 205 bytes ....fillStyle.parse.invalid.css-color-4-hsl-1.html | 31 + ....fillStyle.parse.invalid.css-color-4-hsl-2.html | 31 + ....fillStyle.parse.invalid.css-color-4-hsl-3.html | 31 + ....fillStyle.parse.invalid.css-color-4-hsl-4.html | 31 + ....fillStyle.parse.invalid.css-color-4-hsl-5.html | 31 + ...fillStyle.parse.invalid.css-color-4-hsla-1.html | 31 + ...fillStyle.parse.invalid.css-color-4-hsla-2.html | 31 + ...fillStyle.parse.invalid.css-color-4-hsla-3.html | 31 + ....fillStyle.parse.invalid.css-color-4-rgb-1.html | 31 + ....fillStyle.parse.invalid.css-color-4-rgb-2.html | 31 + ....fillStyle.parse.invalid.css-color-4-rgb-3.html | 31 + ....fillStyle.parse.invalid.css-color-4-rgb-4.html | 31 + ....fillStyle.parse.invalid.css-color-4-rgb-5.html | 31 + ...fillStyle.parse.invalid.css-color-4-rgba-1.html | 31 + ...fillStyle.parse.invalid.css-color-4-rgba-2.html | 31 + ...fillStyle.parse.invalid.css-color-4-rgba-3.html | 31 + .../2d.fillStyle.parse.invalid.hex1.html | 31 + .../2d.fillStyle.parse.invalid.hex2.html | 31 + .../2d.fillStyle.parse.invalid.hex3.html | 31 + .../2d.fillStyle.parse.invalid.hex4.html | 31 + .../2d.fillStyle.parse.invalid.hex5.html | 31 + .../2d.fillStyle.parse.invalid.hex6.html | 31 + .../2d.fillStyle.parse.invalid.hex7.html | 31 + .../2d.fillStyle.parse.invalid.hex8.html | 31 + .../2d.fillStyle.parse.invalid.hsl-1.html | 31 + .../2d.fillStyle.parse.invalid.hsl-2.html | 31 + .../2d.fillStyle.parse.invalid.hsl-3.html | 31 + .../2d.fillStyle.parse.invalid.hsl-4.html | 31 + .../2d.fillStyle.parse.invalid.hsl-5.html | 31 + .../2d.fillStyle.parse.invalid.hsl-6.html | 31 + .../2d.fillStyle.parse.invalid.hsla-1.html | 31 + .../2d.fillStyle.parse.invalid.hsla-2.html | 31 + .../2d.fillStyle.parse.invalid.hsla-3.html | 31 + .../2d.fillStyle.parse.invalid.name-1.html | 31 + .../2d.fillStyle.parse.invalid.name-2.html | 31 + .../2d.fillStyle.parse.invalid.name-3.html | 31 + .../2d.fillStyle.parse.invalid.name-4.html | 31 + .../2d.fillStyle.parse.invalid.name-5.html | 31 + .../2d.fillStyle.parse.invalid.rgb-1.html | 31 + .../2d.fillStyle.parse.invalid.rgb-2.html | 31 + .../2d.fillStyle.parse.invalid.rgb-3.html | 31 + .../2d.fillStyle.parse.invalid.rgba-1.html | 31 + .../2d.fillStyle.parse.invalid.rgba-2.html | 31 + .../2d.fillStyle.parse.invalid.rgba-3.html | 31 + .../2d.fillStyle.parse.invalid.rgba-4.html | 31 + .../2d.fillStyle.parse.invalid.rgba-5.html | 31 + .../2d.fillStyle.parse.rgb-clamp-1.html | 31 + .../2d.fillStyle.parse.rgb-clamp-1.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.rgb-clamp-2.html | 31 + .../2d.fillStyle.parse.rgb-clamp-2.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.rgb-clamp-3.html | 31 + .../2d.fillStyle.parse.rgb-clamp-3.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.rgb-clamp-4.html | 31 + .../2d.fillStyle.parse.rgb-clamp-4.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.rgb-clamp-5.html | 31 + .../2d.fillStyle.parse.rgb-clamp-5.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.rgb-eof.html | 31 + .../2d.fillStyle.parse.rgb-eof.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.rgb-num.html | 31 + .../2d.fillStyle.parse.rgb-num.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.rgb-percent.html | 31 + .../2d.fillStyle.parse.rgb-percent.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.rgba-clamp-1.html | 31 + .../2d.fillStyle.parse.rgba-clamp-1.png | Bin 0 -> 117 bytes .../2d.fillStyle.parse.rgba-clamp-2.html | 31 + .../2d.fillStyle.parse.rgba-clamp-2.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.rgba-eof.html | 31 + .../2d.fillStyle.parse.rgba-eof.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.rgba-num-1.html | 31 + .../2d.fillStyle.parse.rgba-num-1.png | Bin 0 -> 220 bytes .../2d.fillStyle.parse.rgba-num-2.html | 31 + .../2d.fillStyle.parse.rgba-num-2.png | Bin 0 -> 220 bytes .../2d.fillStyle.parse.rgba-percent.html | 31 + .../2d.fillStyle.parse.rgba-percent.png | Bin 0 -> 220 bytes .../2d.fillStyle.parse.rgba-solid-1.html | 31 + .../2d.fillStyle.parse.rgba-solid-1.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.rgba-solid-2.html | 31 + .../2d.fillStyle.parse.rgba-solid-2.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.rgba-solid-3.html | 31 + .../2d.fillStyle.parse.rgba-solid-3.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.rgba-solid-4.html | 31 + .../2d.fillStyle.parse.rgba-solid-4.png | Bin 0 -> 205 bytes .../2d.fillStyle.parse.svg-1.html | 31 + .../2d.fillStyle.parse.svg-1.png | Bin 0 -> 207 bytes .../2d.fillStyle.parse.svg-2.html | 31 + .../2d.fillStyle.parse.svg-2.png | Bin 0 -> 207 bytes .../2d.fillStyle.parse.system.html | 30 + .../2d.fillStyle.parse.transparent-1.html | 31 + .../2d.fillStyle.parse.transparent-1.png | Bin 0 -> 117 bytes .../2d.fillStyle.parse.transparent-2.html | 31 + .../2d.fillStyle.parse.transparent-2.png | Bin 0 -> 117 bytes .../fill-and-stroke-styles/2d.gradient.empty.html | 32 + .../2d.gradient.interpolate.alpha.html | 36 + .../2d.gradient.interpolate.alpha.png | Bin 0 -> 222 bytes .../2d.gradient.interpolate.colour.html | 34 + .../2d.gradient.interpolate.colour.png | Bin 0 -> 222 bytes .../2d.gradient.interpolate.colouralpha.html | 34 + .../2d.gradient.interpolate.colouralpha.png | Bin 0 -> 401 bytes .../2d.gradient.interpolate.multiple.html | 36 + .../2d.gradient.interpolate.multiple.png | Bin 0 -> 262 bytes .../2d.gradient.interpolate.outside.html | 38 + .../2d.gradient.interpolate.overlap.html | 52 + .../2d.gradient.interpolate.overlap.png | Bin 0 -> 253 bytes .../2d.gradient.interpolate.overlap2.html | 42 + .../2d.gradient.interpolate.solid.html | 32 + .../2d.gradient.interpolate.vertical.html | 34 + .../2d.gradient.interpolate.vertical.png | Bin 0 -> 231 bytes .../2d.gradient.interpolate.zerosize.fill.html | 36 + .../2d.gradient.interpolate.zerosize.fillRect.html | 35 + .../2d.gradient.interpolate.zerosize.fillText.html | 36 + .../2d.gradient.interpolate.zerosize.stroke.html | 44 + ...d.gradient.interpolate.zerosize.strokeRect.html | 43 + ...d.gradient.interpolate.zerosize.strokeText.html | 36 + .../2d.gradient.linear.nonfinite.html | 49 + .../2d.gradient.linear.transform.1.html | 37 + .../2d.gradient.linear.transform.2.html | 38 + .../2d.gradient.linear.transform.3.html | 38 + .../2d.gradient.object.compare.html | 31 + .../2d.gradient.object.crosscanvas.html | 34 + .../2d.gradient.object.current.html | 37 + .../2d.gradient.object.current.png | Bin 0 -> 112 bytes .../2d.gradient.object.invalidcolour.html | 32 + .../2d.gradient.object.invalidoffset.html | 32 + .../2d.gradient.object.return.html | 35 + .../2d.gradient.object.type.html | 28 + .../2d.gradient.object.update.html | 34 + .../2d.gradient.radial.cone.behind.html | 44 + .../2d.gradient.radial.cone.beside.html | 44 + .../2d.gradient.radial.cone.bottom.html | 44 + .../2d.gradient.radial.cone.cylinder.html | 44 + .../2d.gradient.radial.cone.front.html | 44 + .../2d.gradient.radial.cone.shape1.html | 53 + .../2d.gradient.radial.cone.shape2.html | 53 + .../2d.gradient.radial.cone.top.html | 44 + .../2d.gradient.radial.equal.html | 44 + .../2d.gradient.radial.inside1.html | 44 + .../2d.gradient.radial.inside2.html | 44 + .../2d.gradient.radial.inside3.html | 45 + .../2d.gradient.radial.negative.html | 29 + .../2d.gradient.radial.nonfinite.html | 101 + .../2d.gradient.radial.outside1.html | 44 + .../2d.gradient.radial.outside2.html | 44 + .../2d.gradient.radial.outside3.html | 45 + .../2d.gradient.radial.touch1.html | 44 + .../2d.gradient.radial.touch2.html | 46 + .../2d.gradient.radial.touch3.html | 44 + .../2d.gradient.radial.transform.1.html | 38 + .../2d.gradient.radial.transform.2.html | 39 + .../2d.gradient.radial.transform.3.html | 39 + .../2d.pattern.animated.gif.html | 38 + .../2d.pattern.basic.canvas.html | 49 + .../2d.pattern.basic.image.html | 38 + .../2d.pattern.basic.nocontext.html | 41 + .../2d.pattern.basic.type.html | 34 + .../2d.pattern.basic.zerocanvas.html | 43 + .../2d.pattern.crosscanvas.html | 36 + .../2d.pattern.image.broken.html | 29 + .../2d.pattern.image.incomplete.emptysrc.html | 30 + .../2d.pattern.image.incomplete.immediate.html | 34 + .../2d.pattern.image.incomplete.nosrc.html | 28 + .../2d.pattern.image.incomplete.reload.html | 36 + .../2d.pattern.image.incomplete.removedsrc.html | 30 + .../2d.pattern.image.null.html | 27 + .../2d.pattern.image.string.html | 27 + .../2d.pattern.image.undefined.html | 27 + .../2d.pattern.modify.canvas1.html | 45 + .../2d.pattern.modify.canvas2.html | 49 + .../2d.pattern.modify.image1.html | 41 + .../2d.pattern.modify.image2.html | 45 + .../2d.pattern.paint.norepeat.basic.html | 39 + .../2d.pattern.paint.norepeat.coord1.html | 42 + .../2d.pattern.paint.norepeat.coord2.html | 43 + .../2d.pattern.paint.norepeat.coord3.html | 43 + .../2d.pattern.paint.norepeat.outside.html | 45 + .../2d.pattern.paint.orientation.canvas.html | 48 + .../2d.pattern.paint.orientation.image.html | 45 + .../2d.pattern.paint.repeat.basic.html | 39 + .../2d.pattern.paint.repeat.coord1.html | 40 + .../2d.pattern.paint.repeat.coord2.html | 36 + .../2d.pattern.paint.repeat.coord3.html | 39 + .../2d.pattern.paint.repeat.outside.html | 40 + .../2d.pattern.paint.repeatx.basic.html | 41 + .../2d.pattern.paint.repeatx.coord1.html | 45 + .../2d.pattern.paint.repeatx.outside.html | 42 + .../2d.pattern.paint.repeaty.basic.html | 41 + .../2d.pattern.paint.repeaty.coord1.html | 45 + .../2d.pattern.paint.repeaty.outside.html | 42 + .../2d.pattern.repeat.case.html | 27 + .../2d.pattern.repeat.empty.html | 38 + .../2d.pattern.repeat.null.html | 27 + .../2d.pattern.repeat.nullsuffix.html | 27 + .../2d.pattern.repeat.undefined.html | 27 + .../2d.pattern.repeat.unrecognised.html | 27 + .../2d.pattern.repeat.unrecognisednull.html | 27 + .../2d.strokeStyle.default.html | 27 + ...as_colorsandstyles_createlineargradient_001.htm | 59 + .../web-platform/tests/2dcontext/green-100x50.png | Bin 0 -> 205 bytes .../tests/2dcontext/hit-regions/.gitkeep | 0 .../addHitRegions-NotSupportedError-01.html | 89 + .../hit-regions/hitregions-members-exist.html | 29 + .../2dcontext/image-smoothing/imagesmoothing.html | 119 + .../tests/2dcontext/line-styles/.gitkeep | 0 .../2dcontext/line-styles/2d.line.cap.butt.html | 61 + .../2dcontext/line-styles/2d.line.cap.closed.html | 46 + .../2dcontext/line-styles/2d.line.cap.invalid.html | 52 + .../2dcontext/line-styles/2d.line.cap.open.html | 46 + .../2dcontext/line-styles/2d.line.cap.round.html | 77 + .../2dcontext/line-styles/2d.line.cap.square.html | 61 + .../2dcontext/line-styles/2d.line.cap.valid.html | 34 + .../tests/2dcontext/line-styles/2d.line.cross.html | 43 + .../2dcontext/line-styles/2d.line.defaults.html | 30 + .../2dcontext/line-styles/2d.line.join.bevel.html | 80 + .../2dcontext/line-styles/2d.line.join.closed.html | 45 + .../line-styles/2d.line.join.invalid.html | 52 + .../2dcontext/line-styles/2d.line.join.miter.html | 71 + .../2dcontext/line-styles/2d.line.join.open.html | 45 + .../line-styles/2d.line.join.parallel.html | 42 + .../2dcontext/line-styles/2d.line.join.round.html | 78 + .../2dcontext/line-styles/2d.line.join.valid.html | 34 + .../2dcontext/line-styles/2d.line.miter.acute.html | 52 + .../line-styles/2d.line.miter.exceeded.html | 44 + .../line-styles/2d.line.miter.invalid.html | 48 + .../line-styles/2d.line.miter.lineedge.html | 41 + .../line-styles/2d.line.miter.obtuse.html | 52 + .../line-styles/2d.line.miter.rightangle.html | 44 + .../2dcontext/line-styles/2d.line.miter.valid.html | 37 + .../line-styles/2d.line.miter.within.html | 44 + .../tests/2dcontext/line-styles/2d.line.union.html | 46 + .../2dcontext/line-styles/2d.line.width.basic.html | 63 + .../line-styles/2d.line.width.invalid.html | 48 + .../line-styles/2d.line.width.scaledefault.html | 40 + .../line-styles/2d.line.width.transformed.html | 69 + .../2dcontext/line-styles/2d.line.width.valid.html | 37 + .../canvas_linestyles_linecap_001-ref.htm | 11 + .../line-styles/canvas_linestyles_linecap_001.htm | 37 + .../tests/2dcontext/line-styles/lineto_a.html | 26 + .../tests/2dcontext/line-styles/lineto_ref.html | 15 + .../tests/2dcontext/line-styles/setLineDash.html | 104 + .../tests/2dcontext/path-objects/.gitkeep | 0 .../path-objects/2d.path.arc.angle.1.html | 34 + .../path-objects/2d.path.arc.angle.2.html | 34 + .../path-objects/2d.path.arc.angle.3.html | 34 + .../path-objects/2d.path.arc.angle.4.html | 37 + .../path-objects/2d.path.arc.angle.5.html | 34 + .../path-objects/2d.path.arc.angle.6.html | 37 + .../path-objects/2d.path.arc.default.html | 34 + .../2dcontext/path-objects/2d.path.arc.empty.html | 34 + .../2dcontext/path-objects/2d.path.arc.end.html | 36 + .../path-objects/2d.path.arc.negative.html | 27 + .../path-objects/2d.path.arc.nonempty.html | 35 + .../path-objects/2d.path.arc.nonfinite.html | 77 + .../path-objects/2d.path.arc.scale.1.html | 54 + .../path-objects/2d.path.arc.scale.2.html | 44 + .../path-objects/2d.path.arc.selfintersect.1.html | 38 + .../path-objects/2d.path.arc.selfintersect.2.html | 42 + .../path-objects/2d.path.arc.shape.1.html | 39 + .../path-objects/2d.path.arc.shape.2.html | 39 + .../path-objects/2d.path.arc.shape.3.html | 38 + .../path-objects/2d.path.arc.shape.4.html | 38 + .../path-objects/2d.path.arc.shape.5.html | 38 + .../path-objects/2d.path.arc.twopie.1.html | 34 + .../path-objects/2d.path.arc.twopie.2.html | 34 + .../path-objects/2d.path.arc.twopie.3.html | 34 + .../path-objects/2d.path.arc.twopie.4.html | 34 + .../2dcontext/path-objects/2d.path.arc.zero.1.html | 34 + .../2dcontext/path-objects/2d.path.arc.zero.2.html | 34 + .../path-objects/2d.path.arc.zeroradius.html | 35 + .../path-objects/2d.path.arcTo.coincide.1.html | 46 + .../path-objects/2d.path.arcTo.coincide.2.html | 36 + .../path-objects/2d.path.arcTo.collinear.1.html | 43 + .../path-objects/2d.path.arcTo.collinear.2.html | 43 + .../path-objects/2d.path.arcTo.collinear.3.html | 48 + .../2d.path.arcTo.ensuresubpath.1.html | 34 + .../2d.path.arcTo.ensuresubpath.2.html | 35 + .../path-objects/2d.path.arcTo.negative.html | 27 + .../path-objects/2d.path.arcTo.nonfinite.html | 75 + .../path-objects/2d.path.arcTo.scale.html | 47 + .../path-objects/2d.path.arcTo.shape.curve1.html | 60 + .../path-objects/2d.path.arcTo.shape.curve2.html | 59 + .../path-objects/2d.path.arcTo.shape.end.html | 40 + .../path-objects/2d.path.arcTo.shape.start.html | 40 + .../path-objects/2d.path.arcTo.transformation.html | 46 + .../path-objects/2d.path.arcTo.zero.1.html | 43 + .../path-objects/2d.path.arcTo.zero.2.html | 43 + .../2dcontext/path-objects/2d.path.beginPath.html | 33 + .../path-objects/2d.path.bezierCurveTo.basic.html | 35 + .../2d.path.bezierCurveTo.ensuresubpath.1.html | 35 + .../2d.path.bezierCurveTo.ensuresubpath.2.html | 35 + .../2d.path.bezierCurveTo.nonfinite.html | 109 + .../path-objects/2d.path.bezierCurveTo.scaled.html | 40 + .../path-objects/2d.path.bezierCurveTo.shape.html | 39 + .../path-objects/2d.path.clip.basic.1.html | 37 + .../path-objects/2d.path.clip.basic.2.html | 37 + .../2dcontext/path-objects/2d.path.clip.empty.html | 36 + .../path-objects/2d.path.clip.intersect.html | 40 + .../path-objects/2d.path.clip.unaffected.html | 42 + .../path-objects/2d.path.clip.winding.1.html | 45 + .../path-objects/2d.path.clip.winding.2.html | 49 + .../path-objects/2d.path.closePath.empty.html | 32 + .../path-objects/2d.path.closePath.newline.html | 37 + .../path-objects/2d.path.closePath.nextpoint.html | 36 + .../path-objects/2d.path.fill.closed.basic.html | 37 + .../2d.path.fill.closed.unaffected.html | 40 + .../path-objects/2d.path.fill.overlap.html | 36 + .../path-objects/2d.path.fill.overlap.png | Bin 0 -> 205 bytes .../path-objects/2d.path.fill.winding.add.html | 42 + .../2d.path.fill.winding.subtract.1.html | 42 + .../2d.path.fill.winding.subtract.2.html | 41 + .../2d.path.fill.winding.subtract.3.html | 47 + .../2dcontext/path-objects/2d.path.initial.html | 32 + .../path-objects/2d.path.isPointInPath.arc.html | 35 + .../2d.path.isPointInPath.basic.1.html | 29 + .../2d.path.isPointInPath.basic.2.html | 29 + .../path-objects/2d.path.isPointInPath.bezier.html | 48 + .../path-objects/2d.path.isPointInPath.bigarc.html | 35 + .../path-objects/2d.path.isPointInPath.edge.html | 39 + .../path-objects/2d.path.isPointInPath.empty.html | 27 + .../2d.path.isPointInPath.nonfinite.html | 34 + .../2d.path.isPointInPath.outside.html | 34 + .../2d.path.isPointInPath.subpath.html | 34 + .../2d.path.isPointInPath.transform.1.html | 34 + .../2d.path.isPointInPath.transform.2.html | 34 + .../2d.path.isPointInPath.transform.3.html | 34 + .../2d.path.isPointInPath.transform.4.html | 32 + .../2d.path.isPointInPath.unclosed.html | 32 + .../2d.path.isPointInPath.winding.html | 47 + .../path-objects/2d.path.lineTo.basic.html | 35 + .../2d.path.lineTo.ensuresubpath.1.html | 34 + .../2d.path.lineTo.ensuresubpath.2.html | 35 + .../path-objects/2d.path.lineTo.nextpoint.html | 36 + .../2d.path.lineTo.nonfinite.details.html | 31 + .../path-objects/2d.path.lineTo.nonfinite.html | 41 + .../path-objects/2d.path.moveTo.basic.html | 36 + .../path-objects/2d.path.moveTo.multiple.html | 36 + .../path-objects/2d.path.moveTo.newsubpath.html | 36 + .../path-objects/2d.path.moveTo.nonfinite.html | 40 + .../2d.path.quadraticCurveTo.basic.html | 35 + .../2d.path.quadraticCurveTo.ensuresubpath.1.html | 35 + .../2d.path.quadraticCurveTo.ensuresubpath.2.html | 35 + .../2d.path.quadraticCurveTo.nonfinite.html | 57 + .../2d.path.quadraticCurveTo.scaled.html | 40 + .../2d.path.quadraticCurveTo.shape.html | 39 + .../2dcontext/path-objects/2d.path.rect.basic.html | 32 + .../path-objects/2d.path.rect.closed.html | 34 + .../2dcontext/path-objects/2d.path.rect.end.1.html | 34 + .../2dcontext/path-objects/2d.path.rect.end.2.html | 39 + .../path-objects/2d.path.rect.negative.html | 39 + .../path-objects/2d.path.rect.newsubpath.html | 36 + .../path-objects/2d.path.rect.nonfinite.html | 57 + .../path-objects/2d.path.rect.selfintersect.html | 34 + .../path-objects/2d.path.rect.winding.html | 39 + .../path-objects/2d.path.rect.zero.1.html | 34 + .../path-objects/2d.path.rect.zero.2.html | 34 + .../path-objects/2d.path.rect.zero.3.html | 34 + .../path-objects/2d.path.rect.zero.4.html | 34 + .../path-objects/2d.path.rect.zero.5.html | 34 + .../path-objects/2d.path.rect.zero.6.html | 36 + .../path-objects/2d.path.stroke.empty.html | 40 + .../path-objects/2d.path.stroke.overlap.html | 38 + .../path-objects/2d.path.stroke.overlap.png | Bin 0 -> 205 bytes .../path-objects/2d.path.stroke.prune.arc.html | 45 + .../path-objects/2d.path.stroke.prune.closed.html | 41 + .../path-objects/2d.path.stroke.prune.corner.html | 43 + .../path-objects/2d.path.stroke.prune.curve.html | 45 + .../path-objects/2d.path.stroke.prune.line.html | 40 + .../path-objects/2d.path.stroke.prune.rect.html | 41 + .../path-objects/2d.path.stroke.scale1.html | 54 + .../path-objects/2d.path.stroke.scale2.html | 56 + .../path-objects/2d.path.stroke.skew.html | 70 + .../path-objects/2d.path.stroke.unaffected.html | 42 + .../path-objects/2d.path.stroke.union.html | 38 + .../path-objects/2d.path.transformation.basic.html | 36 + .../2d.path.transformation.changing.html | 42 + .../2d.path.transformation.multiple.html | 47 + .../tests/2dcontext/pixel-manipulation/.gitkeep | 0 .../2d.imageData.create1.basic.html | 27 + .../2d.imageData.create1.initial.html | 38 + .../2d.imageData.create1.this.html | 30 + .../2d.imageData.create1.type.html | 33 + .../2d.imageData.create1.zero.html | 27 + .../2d.imageData.create2.basic.html | 27 + .../2d.imageData.create2.initial.html | 35 + .../2d.imageData.create2.large.html | 35 + .../2d.imageData.create2.negative.html | 33 + .../2d.imageData.create2.nonfinite.html | 43 + .../2d.imageData.create2.round.html | 30 + .../2d.imageData.create2.this.html | 29 + .../2d.imageData.create2.tiny.html | 35 + .../2d.imageData.create2.type.html | 33 + .../2d.imageData.create2.zero.html | 29 + .../pixel-manipulation/2d.imageData.get.basic.html | 27 + .../pixel-manipulation/2d.imageData.get.clamp.html | 38 + .../2d.imageData.get.length.html | 28 + .../2d.imageData.get.nonfinite.html | 75 + .../2d.imageData.get.nonpremul.html | 34 + .../2d.imageData.get.order.alpha.html | 31 + .../2d.imageData.get.order.cols.html | 34 + .../2d.imageData.get.order.rgb.html | 37 + .../2d.imageData.get.order.rows.html | 34 + .../pixel-manipulation/2d.imageData.get.range.html | 34 + .../2d.imageData.get.source.negative.html | 46 + .../2d.imageData.get.source.outside.html | 86 + .../2d.imageData.get.source.size.html | 30 + .../pixel-manipulation/2d.imageData.get.tiny.html | 30 + .../pixel-manipulation/2d.imageData.get.type.html | 33 + .../2d.imageData.get.unaffected.html | 42 + .../pixel-manipulation/2d.imageData.get.zero.html | 29 + .../2d.imageData.object.clamp.html | 55 + .../2d.imageData.object.ctor.html | 28 + .../2d.imageData.object.nan.html | 33 + .../2d.imageData.object.properties.html | 30 + .../2d.imageData.object.readonly.html | 40 + .../2d.imageData.object.round.html | 55 + .../2d.imageData.object.set.html | 31 + .../2d.imageData.object.string.html | 36 + .../2d.imageData.object.undefined.html | 30 + .../pixel-manipulation/2d.imageData.put.alpha.html | 33 + .../pixel-manipulation/2d.imageData.put.alpha.png | Bin 0 -> 221 bytes .../pixel-manipulation/2d.imageData.put.basic.html | 33 + .../pixel-manipulation/2d.imageData.put.clip.html | 37 + .../2d.imageData.put.created.html | 37 + .../pixel-manipulation/2d.imageData.put.cross.html | 35 + .../2d.imageData.put.dirty.negative.html | 44 + .../2d.imageData.put.dirty.outside.html | 46 + .../2d.imageData.put.dirty.rect1.html | 44 + .../2d.imageData.put.dirty.rect2.html | 44 + .../2d.imageData.put.dirty.zero.html | 33 + .../2d.imageData.put.modified.html | 38 + .../2d.imageData.put.nonfinite.html | 109 + .../pixel-manipulation/2d.imageData.put.null.html | 27 + .../pixel-manipulation/2d.imageData.put.path.html | 34 + .../2d.imageData.put.unaffected.html | 39 + .../2d.imageData.put.unchanged.html | 44 + .../2d.imageData.put.wrongtype.html | 30 + .../web-platform/tests/2dcontext/shadows/.gitkeep | 0 .../tests/2dcontext/shadows/2d.shadow.alpha.1.html | 33 + .../tests/2dcontext/shadows/2d.shadow.alpha.2.html | 33 + .../tests/2dcontext/shadows/2d.shadow.alpha.2.png | Bin 0 -> 206 bytes .../tests/2dcontext/shadows/2d.shadow.alpha.3.html | 35 + .../tests/2dcontext/shadows/2d.shadow.alpha.3.png | Bin 0 -> 206 bytes .../tests/2dcontext/shadows/2d.shadow.alpha.4.html | 35 + .../tests/2dcontext/shadows/2d.shadow.alpha.4.png | Bin 0 -> 206 bytes .../tests/2dcontext/shadows/2d.shadow.alpha.5.html | 34 + .../tests/2dcontext/shadows/2d.shadow.alpha.5.png | Bin 0 -> 206 bytes .../2d.shadow.attributes.shadowBlur.initial.html | 27 + .../2d.shadow.attributes.shadowBlur.invalid.html | 41 + .../2d.shadow.attributes.shadowBlur.valid.html | 37 + .../2d.shadow.attributes.shadowColor.initial.html | 27 + .../2d.shadow.attributes.shadowColor.invalid.html | 41 + .../2d.shadow.attributes.shadowColor.valid.html | 31 + .../2d.shadow.attributes.shadowOffset.initial.html | 28 + .../2d.shadow.attributes.shadowOffset.invalid.html | 46 + .../2d.shadow.attributes.shadowOffset.valid.html | 50 + .../shadows/2d.shadow.blur.high-manual.html | 32 + .../2dcontext/shadows/2d.shadow.blur.high.png | Bin 0 -> 246 bytes .../shadows/2d.shadow.blur.low-manual.html | 39 + .../tests/2dcontext/shadows/2d.shadow.blur.low.png | Bin 0 -> 1588 bytes .../2dcontext/shadows/2d.shadow.canvas.alpha.html | 41 + .../2dcontext/shadows/2d.shadow.canvas.alpha.png | Bin 0 -> 206 bytes .../2dcontext/shadows/2d.shadow.canvas.basic.html | 40 + .../shadows/2d.shadow.canvas.transparent.1.html | 38 + .../shadows/2d.shadow.canvas.transparent.2.html | 46 + .../tests/2dcontext/shadows/2d.shadow.clip.1.html | 42 + .../tests/2dcontext/shadows/2d.shadow.clip.2.html | 42 + .../tests/2dcontext/shadows/2d.shadow.clip.3.html | 43 + .../2dcontext/shadows/2d.shadow.composite.1.html | 35 + .../2dcontext/shadows/2d.shadow.composite.2.html | 35 + .../2dcontext/shadows/2d.shadow.composite.3.html | 36 + .../2dcontext/shadows/2d.shadow.enable.blur.html | 32 + .../2dcontext/shadows/2d.shadow.enable.off.1.html | 30 + .../2dcontext/shadows/2d.shadow.enable.off.2.html | 31 + .../2dcontext/shadows/2d.shadow.enable.x.html | 32 + .../2dcontext/shadows/2d.shadow.enable.y.html | 32 + .../shadows/2d.shadow.gradient.alpha.html | 37 + .../2dcontext/shadows/2d.shadow.gradient.alpha.png | Bin 0 -> 206 bytes .../shadows/2d.shadow.gradient.basic.html | 37 + .../shadows/2d.shadow.gradient.transparent.1.html | 37 + .../shadows/2d.shadow.gradient.transparent.2.html | 43 + .../2dcontext/shadows/2d.shadow.image.alpha.html | 34 + .../2dcontext/shadows/2d.shadow.image.alpha.png | Bin 0 -> 206 bytes .../2dcontext/shadows/2d.shadow.image.basic.html | 34 + .../2dcontext/shadows/2d.shadow.image.scale.html | 36 + .../2dcontext/shadows/2d.shadow.image.section.html | 36 + .../shadows/2d.shadow.image.transparent.1.html | 34 + .../shadows/2d.shadow.image.transparent.2.html | 40 + .../shadows/2d.shadow.offset.negativeX.html | 34 + .../shadows/2d.shadow.offset.negativeY.html | 34 + .../shadows/2d.shadow.offset.positiveX.html | 34 + .../shadows/2d.shadow.offset.positiveY.html | 34 + .../tests/2dcontext/shadows/2d.shadow.outside.html | 42 + .../2dcontext/shadows/2d.shadow.pattern.alpha.html | 36 + .../2dcontext/shadows/2d.shadow.pattern.alpha.png | Bin 0 -> 206 bytes .../2dcontext/shadows/2d.shadow.pattern.basic.html | 36 + .../shadows/2d.shadow.pattern.transparent.1.html | 36 + .../shadows/2d.shadow.pattern.transparent.2.html | 40 + .../2dcontext/shadows/2d.shadow.stroke.basic.html | 40 + .../2dcontext/shadows/2d.shadow.stroke.cap.1.html | 43 + .../2dcontext/shadows/2d.shadow.stroke.cap.2.html | 41 + .../2dcontext/shadows/2d.shadow.stroke.join.1.html | 43 + .../2dcontext/shadows/2d.shadow.stroke.join.2.html | 45 + .../2dcontext/shadows/2d.shadow.stroke.join.3.html | 44 + .../2dcontext/shadows/2d.shadow.transform.1.html | 34 + .../2dcontext/shadows/2d.shadow.transform.2.html | 34 + .../tests/2dcontext/shadows/canvas_shadows_001.htm | 60 + .../2dcontext/shadows/canvas_shadows_002-ref.htm | 27 + .../tests/2dcontext/shadows/canvas_shadows_002.htm | 34 + .../tests/2dcontext/text-styles/.gitkeep | 0 .../text-styles/2d.text.align.default.html | 27 + .../text-styles/2d.text.align.invalid.html | 41 + .../2dcontext/text-styles/2d.text.align.valid.html | 40 + .../text-styles/2d.text.baseline.default.html | 27 + .../text-styles/2d.text.baseline.invalid.html | 41 + .../text-styles/2d.text.baseline.valid.html | 43 + .../text-styles/2d.text.draw.baseline.bottom.html | 48 + .../text-styles/2d.text.draw.baseline.hanging.html | 48 + .../2d.text.draw.baseline.ideographic.html | 48 + .../text-styles/2d.text.draw.baseline.middle.html | 48 + .../text-styles/2d.text.draw.baseline.top.html | 48 + .../2d.text.draw.space.collapse.end.html | 44 + .../2d.text.draw.space.collapse.other.html | 43 + .../2d.text.draw.space.collapse.space.html | 43 + .../2d.text.draw.space.collapse.start.html | 43 + .../text-styles/2d.text.font.default.html | 27 + .../text-styles/2d.text.font.parse.basic.html | 31 + .../text-styles/2d.text.font.parse.complex.html | 28 + .../text-styles/2d.text.font.parse.invalid.html | 56 + ...2d.text.font.parse.size.percentage.default.html | 30 + .../2d.text.font.parse.size.percentage.html | 30 + .../text-styles/2d.text.font.parse.system.html | 28 + .../text-styles/2d.text.measure.width.space.html | 44 + .../text-styles/canvas_text_font_001-ref.htm | 22 + .../2dcontext/text-styles/canvas_text_font_001.htm | 33 + .../tests/2dcontext/the-canvas-state/.gitkeep | 0 .../2d.state.saverestore.bitmap.html | 33 + .../2d.state.saverestore.clip.html | 35 + .../2d.state.saverestore.fillStyle.html | 41 + .../2d.state.saverestore.font.html | 41 + .../2d.state.saverestore.globalAlpha.html | 41 + ...state.saverestore.globalCompositeOperation.html | 41 + ...2d.state.saverestore.imageSmoothingEnabled.html | 47 + .../2d.state.saverestore.lineCap.html | 41 + .../2d.state.saverestore.lineJoin.html | 41 + .../2d.state.saverestore.lineWidth.html | 41 + .../2d.state.saverestore.miterLimit.html | 41 + .../2d.state.saverestore.path.html | 34 + .../2d.state.saverestore.shadowBlur.html | 41 + .../2d.state.saverestore.shadowColor.html | 41 + .../2d.state.saverestore.shadowOffsetX.html | 41 + .../2d.state.saverestore.shadowOffsetY.html | 41 + .../2d.state.saverestore.stack.html | 36 + .../2d.state.saverestore.stackdepth.html | 37 + .../2d.state.saverestore.strokeStyle.html | 41 + .../2d.state.saverestore.textAlign.html | 41 + .../2d.state.saverestore.textBaseline.html | 41 + .../2d.state.saverestore.transformation.html | 34 + .../2d.state.saverestore.underflow.html | 31 + .../canvas_state_restore_001-ref.htm | 11 + .../the-canvas-state/canvas_state_restore_001.htm | 42 + .../web-platform/tests/2dcontext/tools/LICENSE.txt | 36 + .../2dcontext/tools/current-work-canvas.xhtml | 3693 +++++++ .../web-platform/tests/2dcontext/tools/gentest.py | 787 ++ .../tests/2dcontext/tools/name2dir.yaml | 45 + .../web-platform/tests/2dcontext/tools/spec.yaml | 717 ++ .../tests/2dcontext/tools/specextract.py | 57 + .../tests/2dcontext/tools/templates.yaml | 378 + .../web-platform/tests/2dcontext/tools/tests.yaml | 1068 ++ .../tests/2dcontext/tools/tests2d.yaml | 10092 +++++++++++++++++++ .../tests/2dcontext/tools/tests2dtext.yaml | 1013 ++ .../tests/2dcontext/transformations/.gitkeep | 0 .../transformations/2d.transformation.order.html | 34 + .../2d.transformation.rotate.direction.html | 33 + .../2d.transformation.rotate.nonfinite.html | 38 + .../2d.transformation.rotate.radians.html | 33 + .../2d.transformation.rotate.wrap.html | 38 + .../2d.transformation.rotate.wrapnegative.html | 35 + .../2d.transformation.rotate.zero.html | 33 + .../2d.transformation.scale.basic.html | 33 + .../2d.transformation.scale.large.html | 33 + .../2d.transformation.scale.multiple.html | 34 + .../2d.transformation.scale.negative.html | 42 + .../2d.transformation.scale.nonfinite.html | 42 + .../2d.transformation.scale.zero.html | 46 + .../2d.transformation.setTransform.multiple.html | 34 + .../2d.transformation.setTransform.nonfinite.html | 110 + .../2d.transformation.setTransform.skewed.html | 55 + .../2d.transformation.transform.identity.html | 33 + .../2d.transformation.transform.multiply.html | 34 + .../2d.transformation.transform.nonfinite.html | 110 + .../2d.transformation.transform.skewed.html | 55 + .../2d.transformation.translate.basic.html | 33 + .../2d.transformation.translate.nonfinite.html | 42 + .../canvas_transformations_reset_001-ref.html | 21 + .../canvas_transformations_reset_001.html | 22 + .../canvas_transformations_scale_001-ref.htm | 11 + .../canvas_transformations_scale_001.htm | 30 + .../2dcontext/transformations/transform_a.html | 22 + .../2dcontext/transformations/transform_ref.html | 16 + 1054 files changed, 49952 insertions(+) create mode 100644 testing/web-platform/tests/2dcontext/2x2.png create mode 100644 testing/web-platform/tests/2dcontext/best-practices/.gitkeep create mode 100644 testing/web-platform/tests/2dcontext/building-paths/.gitkeep create mode 100644 testing/web-platform/tests/2dcontext/building-paths/canvas_complexshapes_arcto_001-ref.htm create mode 100644 testing/web-platform/tests/2dcontext/building-paths/canvas_complexshapes_arcto_001.htm create mode 100644 testing/web-platform/tests/2dcontext/building-paths/canvas_complexshapes_beziercurveto_001-ref.htm create mode 100644 testing/web-platform/tests/2dcontext/building-paths/canvas_complexshapes_beziercurveto_001.htm create mode 100644 testing/web-platform/tests/2dcontext/clear-100x50.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/.gitkeep create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.copy.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.copy.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-atop.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-atop.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-in.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-in.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-out.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-out.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-over.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-over.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.lighter.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.lighter.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-atop.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-atop.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-in.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-in.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-out.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-out.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-over.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-over.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.xor.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.xor.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.copy.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.destination-atop.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.destination-in.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.destination-out.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.destination-over.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.lighter.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.source-atop.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.source-in.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.source-out.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.source-over.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.xor.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.canvas.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.canvaspattern.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.default.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.fill.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.image.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.imagepattern.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.invalid.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.range.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.image.copy.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.image.copy.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-atop.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-atop.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-in.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-in.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-out.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-out.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-over.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-over.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.image.lighter.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.image.lighter.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-atop.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-atop.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-in.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-in.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-out.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-out.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-over.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-over.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.image.xor.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.image.xor.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.casesensitive.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.clear.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.darker.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.default.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.get.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.highlight.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.nullsuffix.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.over.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.unrecognised.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.copy.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.copy.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-atop.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-atop.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-in.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-in.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-out.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-out.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-over.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-over.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.lighter.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.lighter.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-atop.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-atop.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-in.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-in.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-out.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-out.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-over.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-over.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.xor.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.xor.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.copy.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.copy.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-atop.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-atop.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-in.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-in.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-out.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-out.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-over.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-over.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.lighter.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.lighter.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-atop.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-atop.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-in.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-in.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-out.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-out.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-over.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-over.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.xor.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.xor.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.copy.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.copy.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.destination-atop.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.destination-atop.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.destination-in.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.destination-in.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.source-in.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.source-in.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.source-out.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.source-out.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.copy.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.copy.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.destination-atop.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.destination-atop.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.destination-in.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.destination-in.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.source-in.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.source-in.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.source-out.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.source-out.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.copy.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.copy.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.destination-atop.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.destination-atop.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.destination-in.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.destination-in.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.source-in.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.source-in.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.source-out.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.source-out.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.copy.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.copy.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.destination-atop.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.destination-atop.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.destination-in.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.destination-in.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.source-in.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.source-in.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.source-out.html create mode 100644 testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.source-out.png create mode 100644 testing/web-platform/tests/2dcontext/compositing/canvas_compositing_globalcompositeoperation_001-ref.htm create mode 100644 testing/web-platform/tests/2dcontext/compositing/canvas_compositing_globalcompositeoperation_001.htm create mode 100644 testing/web-platform/tests/2dcontext/conformance-requirements/.gitkeep create mode 100644 testing/web-platform/tests/2dcontext/conformance-requirements/2d.coordinatespace-manual.html create mode 100644 testing/web-platform/tests/2dcontext/conformance-requirements/2d.coordinatespace.png create mode 100644 testing/web-platform/tests/2dcontext/conformance-requirements/2d.missingargs.html create mode 100644 testing/web-platform/tests/2dcontext/conformance-requirements/2d.type.delete.html create mode 100644 testing/web-platform/tests/2dcontext/conformance-requirements/2d.voidreturn.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/.gitkeep create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.3arg.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.5arg.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.9arg.basic.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.9arg.destpos.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.9arg.destsize.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.9arg.sourcepos.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.9arg.sourcesize.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.alpha.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.animated.apng.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.animated.gif.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.animated.poster.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.broken.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.canvas.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.clip.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.composite.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.floatsource.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.incomplete.emptysrc.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.incomplete.immediate.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.incomplete.nosrc.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.incomplete.reload.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.incomplete.removedsrc.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.negativedest.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.negativedir.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.negativesource.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.nonfinite.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.nowrap.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.null.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.path.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.self.1.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.self.2.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.svg.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.transform.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.wrongtype.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.zerocanvas.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.zerosource.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.zerosource.image.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_1.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_10.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_10_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_11.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_11_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_12.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_12_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_1_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_2.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_2_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_3.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_3_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_4.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_4_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_5.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_5_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_6.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_6_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_7.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_7_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_8.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_8_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_9.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_9_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_1.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_10.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_10_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_11.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_11_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_12.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_12_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_13.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_13_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_1_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_2.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_2_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_3.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_3_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_4.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_4_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_5.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_5_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_6.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_6_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_7.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_7_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_8.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_8_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_9.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_9_ref.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-model/.gitkeep create mode 100644 testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/.gitkeep create mode 100644 testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/canvas_complexshapes_ispointInpath_001.htm create mode 100644 testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/canvas_focus_drawCustomFocusRing_001.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/canvas_focus_drawFocusIfNeeded_AAPI_001-manual.html create mode 100755 testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/drawFocusIfNeeded_001.html create mode 100755 testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/drawFocusIfNeeded_002.html create mode 100755 testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/drawFocusIfNeeded_003.html create mode 100755 testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/drawFocusIfNeeded_004.html create mode 100755 testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/drawFocusIfNeeded_005.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/.gitkeep create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.basic.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.clip.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.globalalpha.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.globalcomposite.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.negative.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.nonfinite.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.path.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.shadow.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.transform.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.zero.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.basic.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.clip.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.negative.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.nonfinite.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.path.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.shadow.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.transform.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.zero.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.basic.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.clip.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.globalalpha.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.globalcomposite.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.negative.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.nonfinite.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.path.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.shadow.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.transform.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.zero.1.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.zero.2.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.zero.3.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.zero.4.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.zero.5.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/clear-100x50.png create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/.gitkeep create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.center.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.end.ltr.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.end.rtl.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.left.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.right.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.start.ltr.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.start.rtl.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.baseline.alphabetic.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.basic-manual.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.basic.png create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.NaN.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.bound.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.fontface.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.large-manual.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.large.png create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.negative.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.small.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.zero.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.rtl-manual.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.rtl.png create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.unaffected.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fontface.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fontface.notinpage.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fontface.repeat.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.kern.consistent-manual.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.space.basic.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.space.collapse.nonspace.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.stroke.basic-manual.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.stroke.basic.png create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.stroke.unaffected.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.measure.width.basic.html create mode 100644 testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.measure.width.empty.html create mode 100644 testing/web-platform/tests/2dcontext/drawingstyle-objects/.gitkeep create mode 100644 testing/web-platform/tests/2dcontext/examples/.gitkeep create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/.gitkeep create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.default.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.get.semitransparent.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.get.solid.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.get.transparent.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.invalidstring.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.invalidtype.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-1.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-2.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-3.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-4.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-4.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-5.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-5.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-6.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-6.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-7.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-7.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-8.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-8.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-9.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-9.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-1.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-2.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-3.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-4.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-4.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-5.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-5.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-6.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-6.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-7.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-7.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-8.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-8.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-9.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-9.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-1.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-2.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-3.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-4.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-4.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-5.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-5.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-6.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-6.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-1.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-2.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-3.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-4.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-4.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-5.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-5.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-6.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-6.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.current.basic.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.current.changed.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.current.notrendered.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.current.removed.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.current.removed.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex3.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex4.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex4.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex6.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex6.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex8.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex8.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-1.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-2.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-3.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-4.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-4.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-5.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-5.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-6.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-6.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-1.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-2.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-3.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-4.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-4.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-1.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-2.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-1.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-2.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-3.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-4.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-4.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-5.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-5.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-6.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-6.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.html4.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.html4.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsl-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsl-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsl-3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsl-4.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsl-5.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsla-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsla-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsla-3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgb-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgb-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgb-3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgb-4.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgb-5.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgba-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgba-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgba-3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex4.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex5.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex6.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex7.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex8.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-4.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-5.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-6.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsla-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsla-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsla-3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.name-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.name-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.name-3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.name-4.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.name-5.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgb-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgb-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgb-3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgba-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgba-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgba-3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgba-4.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgba-5.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-1.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-2.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-3.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-4.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-4.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-5.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-5.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-eof.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-eof.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-num.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-num.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-percent.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-percent.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-clamp-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-clamp-1.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-clamp-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-clamp-2.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-eof.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-eof.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-num-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-num-1.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-num-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-num-2.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-percent.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-percent.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-1.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-2.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-3.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-4.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-4.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.svg-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.svg-1.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.svg-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.svg-2.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.system.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.transparent-1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.transparent-1.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.transparent-2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.transparent-2.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.empty.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.alpha.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.alpha.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.colour.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.colour.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.colouralpha.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.colouralpha.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.multiple.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.multiple.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.outside.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.overlap.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.overlap.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.overlap2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.solid.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.vertical.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.vertical.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.fill.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.fillRect.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.fillText.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.stroke.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.strokeRect.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.strokeText.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.linear.nonfinite.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.linear.transform.1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.linear.transform.2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.linear.transform.3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.compare.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.crosscanvas.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.current.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.current.png create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.invalidcolour.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.invalidoffset.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.return.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.type.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.update.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.behind.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.beside.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.bottom.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.cylinder.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.front.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.shape1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.shape2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.top.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.equal.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.inside1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.inside2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.inside3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.negative.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.nonfinite.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.outside1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.outside2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.outside3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.touch1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.touch2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.touch3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.transform.1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.transform.2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.transform.3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.animated.gif.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.basic.canvas.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.basic.image.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.basic.nocontext.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.basic.type.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.basic.zerocanvas.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.crosscanvas.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.broken.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.incomplete.emptysrc.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.incomplete.immediate.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.incomplete.nosrc.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.incomplete.reload.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.incomplete.removedsrc.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.null.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.string.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.undefined.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.modify.canvas1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.modify.canvas2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.modify.image1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.modify.image2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.norepeat.basic.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.norepeat.coord1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.norepeat.coord2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.norepeat.coord3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.norepeat.outside.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.orientation.canvas.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.orientation.image.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeat.basic.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeat.coord1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeat.coord2.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeat.coord3.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeat.outside.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeatx.basic.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeatx.coord1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeatx.outside.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeaty.basic.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeaty.coord1.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeaty.outside.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.case.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.empty.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.null.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.nullsuffix.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.undefined.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.unrecognised.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.unrecognisednull.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.strokeStyle.default.html create mode 100644 testing/web-platform/tests/2dcontext/fill-and-stroke-styles/canvas_colorsandstyles_createlineargradient_001.htm create mode 100644 testing/web-platform/tests/2dcontext/green-100x50.png create mode 100644 testing/web-platform/tests/2dcontext/hit-regions/.gitkeep create mode 100644 testing/web-platform/tests/2dcontext/hit-regions/addHitRegions-NotSupportedError-01.html create mode 100644 testing/web-platform/tests/2dcontext/hit-regions/hitregions-members-exist.html create mode 100644 testing/web-platform/tests/2dcontext/image-smoothing/imagesmoothing.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/.gitkeep create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.butt.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.closed.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.invalid.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.open.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.round.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.square.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.valid.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.cross.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.defaults.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.join.bevel.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.join.closed.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.join.invalid.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.join.miter.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.join.open.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.join.parallel.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.join.round.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.join.valid.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.acute.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.exceeded.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.invalid.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.lineedge.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.obtuse.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.rightangle.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.valid.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.within.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.union.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.width.basic.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.width.invalid.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.width.scaledefault.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.width.transformed.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/2d.line.width.valid.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/canvas_linestyles_linecap_001-ref.htm create mode 100644 testing/web-platform/tests/2dcontext/line-styles/canvas_linestyles_linecap_001.htm create mode 100644 testing/web-platform/tests/2dcontext/line-styles/lineto_a.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/lineto_ref.html create mode 100644 testing/web-platform/tests/2dcontext/line-styles/setLineDash.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/.gitkeep create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.1.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.2.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.3.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.4.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.5.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.6.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.default.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.empty.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.end.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.negative.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.nonempty.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.nonfinite.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.scale.1.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.scale.2.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.selfintersect.1.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.selfintersect.2.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.shape.1.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.shape.2.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.shape.3.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.shape.4.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.shape.5.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.twopie.1.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.twopie.2.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.twopie.3.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.twopie.4.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.zero.1.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.zero.2.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.zeroradius.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.coincide.1.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.coincide.2.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.collinear.1.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.collinear.2.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.collinear.3.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.ensuresubpath.1.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.ensuresubpath.2.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.negative.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.nonfinite.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.scale.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.shape.curve1.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.shape.curve2.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.shape.end.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.shape.start.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.transformation.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.zero.1.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.zero.2.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.beginPath.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.basic.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.ensuresubpath.1.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.ensuresubpath.2.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.nonfinite.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.scaled.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.shape.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.basic.1.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.basic.2.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.empty.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.intersect.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.unaffected.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.winding.1.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.winding.2.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.closePath.empty.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.closePath.newline.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.closePath.nextpoint.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.closed.basic.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.closed.unaffected.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.overlap.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.overlap.png create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.winding.add.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.winding.subtract.1.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.winding.subtract.2.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.winding.subtract.3.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.initial.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.arc.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.basic.1.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.basic.2.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.bezier.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.bigarc.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.edge.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.empty.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.nonfinite.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.outside.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.subpath.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.transform.1.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.transform.2.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.transform.3.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.transform.4.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.unclosed.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.winding.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.basic.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.ensuresubpath.1.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.ensuresubpath.2.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.nextpoint.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.nonfinite.details.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.nonfinite.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.moveTo.basic.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.moveTo.multiple.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.moveTo.newsubpath.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.moveTo.nonfinite.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.basic.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.ensuresubpath.1.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.ensuresubpath.2.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.nonfinite.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.scaled.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.shape.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.basic.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.closed.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.end.1.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.end.2.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.negative.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.newsubpath.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.nonfinite.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.selfintersect.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.winding.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.1.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.2.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.3.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.4.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.5.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.6.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.empty.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.overlap.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.overlap.png create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.arc.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.closed.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.corner.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.curve.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.line.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.rect.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.scale1.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.scale2.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.skew.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.unaffected.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.union.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.transformation.basic.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.transformation.changing.html create mode 100644 testing/web-platform/tests/2dcontext/path-objects/2d.path.transformation.multiple.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/.gitkeep create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create1.basic.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create1.initial.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create1.this.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create1.type.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create1.zero.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.basic.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.initial.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.large.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.negative.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.nonfinite.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.round.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.this.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.tiny.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.type.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.zero.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.basic.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.clamp.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.length.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.nonfinite.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.nonpremul.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.order.alpha.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.order.cols.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.order.rgb.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.order.rows.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.range.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.source.negative.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.source.outside.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.source.size.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.tiny.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.type.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.unaffected.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.zero.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.clamp.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.ctor.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.nan.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.properties.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.readonly.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.round.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.set.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.string.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.undefined.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.alpha.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.alpha.png create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.basic.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.clip.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.created.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.cross.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.dirty.negative.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.dirty.outside.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.dirty.rect1.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.dirty.rect2.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.dirty.zero.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.modified.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.nonfinite.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.null.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.path.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.unaffected.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.unchanged.html create mode 100644 testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.wrongtype.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/.gitkeep create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.1.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.2.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.2.png create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.3.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.3.png create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.4.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.4.png create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.5.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.5.png create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowBlur.initial.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowBlur.invalid.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowBlur.valid.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowColor.initial.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowColor.invalid.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowColor.valid.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowOffset.initial.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowOffset.invalid.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowOffset.valid.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.blur.high-manual.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.blur.high.png create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.blur.low-manual.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.blur.low.png create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.canvas.alpha.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.canvas.alpha.png create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.canvas.basic.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.canvas.transparent.1.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.canvas.transparent.2.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.clip.1.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.clip.2.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.clip.3.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.composite.1.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.composite.2.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.composite.3.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.enable.blur.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.enable.off.1.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.enable.off.2.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.enable.x.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.enable.y.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.gradient.alpha.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.gradient.alpha.png create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.gradient.basic.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.gradient.transparent.1.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.gradient.transparent.2.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.alpha.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.alpha.png create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.basic.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.scale.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.section.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.transparent.1.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.transparent.2.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.offset.negativeX.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.offset.negativeY.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.offset.positiveX.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.offset.positiveY.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.outside.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.pattern.alpha.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.pattern.alpha.png create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.pattern.basic.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.pattern.transparent.1.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.pattern.transparent.2.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.basic.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.cap.1.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.cap.2.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.join.1.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.join.2.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.join.3.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.transform.1.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/2d.shadow.transform.2.html create mode 100644 testing/web-platform/tests/2dcontext/shadows/canvas_shadows_001.htm create mode 100644 testing/web-platform/tests/2dcontext/shadows/canvas_shadows_002-ref.htm create mode 100644 testing/web-platform/tests/2dcontext/shadows/canvas_shadows_002.htm create mode 100644 testing/web-platform/tests/2dcontext/text-styles/.gitkeep create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.align.default.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.align.invalid.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.align.valid.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.baseline.default.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.baseline.invalid.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.baseline.valid.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.baseline.bottom.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.baseline.hanging.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.baseline.ideographic.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.baseline.middle.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.baseline.top.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.space.collapse.end.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.space.collapse.other.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.space.collapse.space.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.space.collapse.start.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.font.default.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.basic.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.complex.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.invalid.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.size.percentage.default.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.size.percentage.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.system.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/2d.text.measure.width.space.html create mode 100644 testing/web-platform/tests/2dcontext/text-styles/canvas_text_font_001-ref.htm create mode 100644 testing/web-platform/tests/2dcontext/text-styles/canvas_text_font_001.htm create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/.gitkeep create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.bitmap.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.clip.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.fillStyle.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.font.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.globalAlpha.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.globalCompositeOperation.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.imageSmoothingEnabled.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.lineCap.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.lineJoin.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.lineWidth.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.miterLimit.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.path.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.shadowBlur.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.shadowColor.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.shadowOffsetX.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.shadowOffsetY.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.stack.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.stackdepth.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.strokeStyle.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.textAlign.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.textBaseline.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.transformation.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.underflow.html create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/canvas_state_restore_001-ref.htm create mode 100644 testing/web-platform/tests/2dcontext/the-canvas-state/canvas_state_restore_001.htm create mode 100644 testing/web-platform/tests/2dcontext/tools/LICENSE.txt create mode 100644 testing/web-platform/tests/2dcontext/tools/current-work-canvas.xhtml create mode 100644 testing/web-platform/tests/2dcontext/tools/gentest.py create mode 100644 testing/web-platform/tests/2dcontext/tools/name2dir.yaml create mode 100644 testing/web-platform/tests/2dcontext/tools/spec.yaml create mode 100644 testing/web-platform/tests/2dcontext/tools/specextract.py create mode 100644 testing/web-platform/tests/2dcontext/tools/templates.yaml create mode 100644 testing/web-platform/tests/2dcontext/tools/tests.yaml create mode 100644 testing/web-platform/tests/2dcontext/tools/tests2d.yaml create mode 100644 testing/web-platform/tests/2dcontext/tools/tests2dtext.yaml create mode 100644 testing/web-platform/tests/2dcontext/transformations/.gitkeep create mode 100644 testing/web-platform/tests/2dcontext/transformations/2d.transformation.order.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.direction.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.nonfinite.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.radians.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.wrap.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.wrapnegative.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.zero.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.basic.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.large.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.multiple.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.negative.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.nonfinite.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.zero.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/2d.transformation.setTransform.multiple.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/2d.transformation.setTransform.nonfinite.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/2d.transformation.setTransform.skewed.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/2d.transformation.transform.identity.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/2d.transformation.transform.multiply.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/2d.transformation.transform.nonfinite.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/2d.transformation.transform.skewed.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/2d.transformation.translate.basic.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/2d.transformation.translate.nonfinite.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/canvas_transformations_reset_001-ref.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/canvas_transformations_reset_001.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/canvas_transformations_scale_001-ref.htm create mode 100644 testing/web-platform/tests/2dcontext/transformations/canvas_transformations_scale_001.htm create mode 100644 testing/web-platform/tests/2dcontext/transformations/transform_a.html create mode 100644 testing/web-platform/tests/2dcontext/transformations/transform_ref.html (limited to 'testing/web-platform/tests/2dcontext') diff --git a/testing/web-platform/tests/2dcontext/2x2.png b/testing/web-platform/tests/2dcontext/2x2.png new file mode 100644 index 000000000..276791c43 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/2x2.png differ diff --git a/testing/web-platform/tests/2dcontext/best-practices/.gitkeep b/testing/web-platform/tests/2dcontext/best-practices/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/testing/web-platform/tests/2dcontext/building-paths/.gitkeep b/testing/web-platform/tests/2dcontext/building-paths/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/testing/web-platform/tests/2dcontext/building-paths/canvas_complexshapes_arcto_001-ref.htm b/testing/web-platform/tests/2dcontext/building-paths/canvas_complexshapes_arcto_001-ref.htm new file mode 100644 index 000000000..6fc212ea4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/building-paths/canvas_complexshapes_arcto_001-ref.htm @@ -0,0 +1,11 @@ + + + + HTML5 Canvas Test: arcTo() adds to subpath if same point + + + +

Description: If x1,y1 and x2,y2 are the same point, then arcTo must add x1,y1 to the subpath, and connect that point to x0,y0 with a straight line.

+
line
+ + diff --git a/testing/web-platform/tests/2dcontext/building-paths/canvas_complexshapes_arcto_001.htm b/testing/web-platform/tests/2dcontext/building-paths/canvas_complexshapes_arcto_001.htm new file mode 100644 index 000000000..c3f2fb6f4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/building-paths/canvas_complexshapes_arcto_001.htm @@ -0,0 +1,26 @@ + + + + HTML5 Canvas Test: arcTo() adds to subpath if same point + + + + + + + +

Description: If x1,y1 and x2,y2 are the same point, then arcTo must add x1,y1 to the subpath, and connect that point to x0,y0 with a straight line.

+ Browser does not support HTML5 Canvas. + + diff --git a/testing/web-platform/tests/2dcontext/building-paths/canvas_complexshapes_beziercurveto_001-ref.htm b/testing/web-platform/tests/2dcontext/building-paths/canvas_complexshapes_beziercurveto_001-ref.htm new file mode 100644 index 000000000..935e84c5c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/building-paths/canvas_complexshapes_beziercurveto_001-ref.htm @@ -0,0 +1,11 @@ + + + + HTML5 Canvas Test: bezierCurveTo() must ensure subpaths + + + +

Description: bezierCurveTo(cp1x, cp1y, cp2x, cp2y, x, y) must ensure there is a subpath for the point (cp1x,cp1y) if the context has no subpaths, then it must connect the last point in the subpath to the point (x,y).

+
smiley
+ + diff --git a/testing/web-platform/tests/2dcontext/building-paths/canvas_complexshapes_beziercurveto_001.htm b/testing/web-platform/tests/2dcontext/building-paths/canvas_complexshapes_beziercurveto_001.htm new file mode 100644 index 000000000..d04926eba --- /dev/null +++ b/testing/web-platform/tests/2dcontext/building-paths/canvas_complexshapes_beziercurveto_001.htm @@ -0,0 +1,35 @@ + + + + HTML5 Canvas Test: bezierCurveTo() must ensure subpaths + + + + + + + +

Description: bezierCurveTo(cp1x, cp1y, cp2x, cp2y, x, y) must ensure there is a subpath for the point (cp1x,cp1y) if the context has no subpaths, then it must connect the last point in the subpath to the point (x,y).

+ Browser does not support HTML5 Canvas. + + diff --git a/testing/web-platform/tests/2dcontext/clear-100x50.png b/testing/web-platform/tests/2dcontext/clear-100x50.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/clear-100x50.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/.gitkeep b/testing/web-platform/tests/2dcontext/compositing/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.copy.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.copy.html new file mode 100644 index 000000000..5f32421fb --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.copy.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.composite.canvas.copy + + + + + + +

2d.composite.canvas.copy

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.copy.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.copy.png new file mode 100644 index 000000000..8e0668efb Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.copy.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-atop.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-atop.html new file mode 100644 index 000000000..14261d0be --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-atop.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.composite.canvas.destination-atop + + + + + + +

2d.composite.canvas.destination-atop

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-atop.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-atop.png new file mode 100644 index 000000000..59bdc91e9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-atop.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-in.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-in.html new file mode 100644 index 000000000..2320064fa --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-in.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.composite.canvas.destination-in + + + + + + +

2d.composite.canvas.destination-in

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-in.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-in.png new file mode 100644 index 000000000..790e418a6 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-in.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-out.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-out.html new file mode 100644 index 000000000..5d392eebc --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-out.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.composite.canvas.destination-out + + + + + + +

2d.composite.canvas.destination-out

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-out.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-out.png new file mode 100644 index 000000000..7f5ed1a83 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-out.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-over.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-over.html new file mode 100644 index 000000000..130cbba8f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-over.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.composite.canvas.destination-over + + + + + + +

2d.composite.canvas.destination-over

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-over.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-over.png new file mode 100644 index 000000000..ac8689223 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.destination-over.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.lighter.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.lighter.html new file mode 100644 index 000000000..bab811861 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.lighter.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.composite.canvas.lighter + + + + + + +

2d.composite.canvas.lighter

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.lighter.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.lighter.png new file mode 100644 index 000000000..9ffde4198 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.lighter.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-atop.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-atop.html new file mode 100644 index 000000000..3d19701dd --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-atop.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.composite.canvas.source-atop + + + + + + +

2d.composite.canvas.source-atop

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-atop.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-atop.png new file mode 100644 index 000000000..1ef963019 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-atop.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-in.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-in.html new file mode 100644 index 000000000..dfc1a5af8 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-in.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.composite.canvas.source-in + + + + + + +

2d.composite.canvas.source-in

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-in.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-in.png new file mode 100644 index 000000000..c26cdccf0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-in.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-out.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-out.html new file mode 100644 index 000000000..a4bd322be --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-out.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.composite.canvas.source-out + + + + + + +

2d.composite.canvas.source-out

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-out.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-out.png new file mode 100644 index 000000000..c26cdccf0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-out.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-over.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-over.html new file mode 100644 index 000000000..ff8dc528b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-over.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.composite.canvas.source-over + + + + + + +

2d.composite.canvas.source-over

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-over.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-over.png new file mode 100644 index 000000000..5437608a8 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.source-over.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.xor.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.xor.html new file mode 100644 index 000000000..f39a023f6 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.xor.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.composite.canvas.xor + + + + + + +

2d.composite.canvas.xor

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.xor.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.xor.png new file mode 100644 index 000000000..1ef963019 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.canvas.xor.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.copy.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.copy.html new file mode 100644 index 000000000..08096cf1f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.copy.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.composite.clip.copy + + + + + + +

2d.composite.clip.copy

+

fill() does not affect pixels outside the clip region.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.destination-atop.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.destination-atop.html new file mode 100644 index 000000000..c05cd34b5 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.destination-atop.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.composite.clip.destination-atop + + + + + + +

2d.composite.clip.destination-atop

+

fill() does not affect pixels outside the clip region.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.destination-in.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.destination-in.html new file mode 100644 index 000000000..24aff70cd --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.destination-in.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.composite.clip.destination-in + + + + + + +

2d.composite.clip.destination-in

+

fill() does not affect pixels outside the clip region.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.destination-out.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.destination-out.html new file mode 100644 index 000000000..afeb00984 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.destination-out.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.composite.clip.destination-out + + + + + + +

2d.composite.clip.destination-out

+

fill() does not affect pixels outside the clip region.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.destination-over.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.destination-over.html new file mode 100644 index 000000000..7a258836d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.destination-over.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.composite.clip.destination-over + + + + + + +

2d.composite.clip.destination-over

+

fill() does not affect pixels outside the clip region.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.lighter.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.lighter.html new file mode 100644 index 000000000..ffc864b7b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.lighter.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.composite.clip.lighter + + + + + + +

2d.composite.clip.lighter

+

fill() does not affect pixels outside the clip region.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.source-atop.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.source-atop.html new file mode 100644 index 000000000..4580b5429 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.source-atop.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.composite.clip.source-atop + + + + + + +

2d.composite.clip.source-atop

+

fill() does not affect pixels outside the clip region.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.source-in.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.source-in.html new file mode 100644 index 000000000..79c4e16a6 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.source-in.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.composite.clip.source-in + + + + + + +

2d.composite.clip.source-in

+

fill() does not affect pixels outside the clip region.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.source-out.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.source-out.html new file mode 100644 index 000000000..53456660d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.source-out.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.composite.clip.source-out + + + + + + +

2d.composite.clip.source-out

+

fill() does not affect pixels outside the clip region.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.source-over.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.source-over.html new file mode 100644 index 000000000..98b446a1f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.source-over.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.composite.clip.source-over + + + + + + +

2d.composite.clip.source-over

+

fill() does not affect pixels outside the clip region.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.xor.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.xor.html new file mode 100644 index 000000000..b6e36bc11 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.clip.xor.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.composite.clip.xor + + + + + + +

2d.composite.clip.xor

+

fill() does not affect pixels outside the clip region.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.canvas.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.canvas.html new file mode 100644 index 000000000..0b6df4930 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.canvas.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.composite.globalAlpha.canvas + + + + + + +

2d.composite.globalAlpha.canvas

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.canvaspattern.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.canvaspattern.html new file mode 100644 index 000000000..eeb2442bf --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.canvaspattern.html @@ -0,0 +1,39 @@ + + +Canvas test: 2d.composite.globalAlpha.canvaspattern + + + + + + +

2d.composite.globalAlpha.canvaspattern

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.default.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.default.html new file mode 100644 index 000000000..f84a340fe --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.default.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.composite.globalAlpha.default + + + + + + +

2d.composite.globalAlpha.default

+

+ + +

Actual output:

+

FAIL (fallback content)

+ + + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.fill.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.fill.html new file mode 100644 index 000000000..591fb6b5a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.fill.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.composite.globalAlpha.fill + + + + + + +

2d.composite.globalAlpha.fill

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.image.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.image.html new file mode 100644 index 000000000..b796992de --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.image.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.composite.globalAlpha.image + + + + + + +

2d.composite.globalAlpha.image

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.imagepattern.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.imagepattern.html new file mode 100644 index 000000000..ab8633952 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.imagepattern.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.globalAlpha.imagepattern + + + + + + +

2d.composite.globalAlpha.imagepattern

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.invalid.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.invalid.html new file mode 100644 index 000000000..980ef8380 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.invalid.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.composite.globalAlpha.invalid + + + + + + +

2d.composite.globalAlpha.invalid

+

+ + +

Actual output:

+

FAIL (fallback content)

+ + + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.range.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.range.html new file mode 100644 index 000000000..14926e6eb --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.globalAlpha.range.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.composite.globalAlpha.range + + + + + + +

2d.composite.globalAlpha.range

+

+ + +

Actual output:

+

FAIL (fallback content)

+ + + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.copy.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.copy.html new file mode 100644 index 000000000..96492347b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.copy.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.image.copy + + + + + + +

2d.composite.image.copy

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.copy.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.copy.png new file mode 100644 index 000000000..8e0668efb Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.copy.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-atop.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-atop.html new file mode 100644 index 000000000..221e7b205 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-atop.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.image.destination-atop + + + + + + +

2d.composite.image.destination-atop

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-atop.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-atop.png new file mode 100644 index 000000000..59bdc91e9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-atop.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-in.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-in.html new file mode 100644 index 000000000..b52860205 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-in.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.image.destination-in + + + + + + +

2d.composite.image.destination-in

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-in.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-in.png new file mode 100644 index 000000000..790e418a6 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-in.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-out.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-out.html new file mode 100644 index 000000000..572ad859a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-out.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.image.destination-out + + + + + + +

2d.composite.image.destination-out

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-out.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-out.png new file mode 100644 index 000000000..7f5ed1a83 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-out.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-over.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-over.html new file mode 100644 index 000000000..16131412b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-over.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.image.destination-over + + + + + + +

2d.composite.image.destination-over

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-over.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-over.png new file mode 100644 index 000000000..ac8689223 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.destination-over.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.lighter.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.lighter.html new file mode 100644 index 000000000..f44d6dc32 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.lighter.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.image.lighter + + + + + + +

2d.composite.image.lighter

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.lighter.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.lighter.png new file mode 100644 index 000000000..9ffde4198 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.lighter.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-atop.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-atop.html new file mode 100644 index 000000000..2d3a88a86 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-atop.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.image.source-atop + + + + + + +

2d.composite.image.source-atop

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-atop.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-atop.png new file mode 100644 index 000000000..1ef963019 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-atop.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-in.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-in.html new file mode 100644 index 000000000..a8c1b5848 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-in.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.image.source-in + + + + + + +

2d.composite.image.source-in

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-in.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-in.png new file mode 100644 index 000000000..c26cdccf0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-in.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-out.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-out.html new file mode 100644 index 000000000..079d342c0 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-out.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.image.source-out + + + + + + +

2d.composite.image.source-out

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-out.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-out.png new file mode 100644 index 000000000..c26cdccf0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-out.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-over.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-over.html new file mode 100644 index 000000000..bbb00e2e8 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-over.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.image.source-over + + + + + + +

2d.composite.image.source-over

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-over.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-over.png new file mode 100644 index 000000000..5437608a8 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.source-over.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.xor.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.xor.html new file mode 100644 index 000000000..a38ece5dd --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.xor.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.image.xor + + + + + + +

2d.composite.image.xor

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.xor.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.xor.png new file mode 100644 index 000000000..1ef963019 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.image.xor.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.casesensitive.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.casesensitive.html new file mode 100644 index 000000000..81b72375b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.casesensitive.html @@ -0,0 +1,29 @@ + + +Canvas test: 2d.composite.operation.casesensitive + + + + + + +

2d.composite.operation.casesensitive

+

+ + +

Actual output:

+

FAIL (fallback content)

+ + + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.clear.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.clear.html new file mode 100644 index 000000000..7212cd05f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.clear.html @@ -0,0 +1,29 @@ + + +Canvas test: 2d.composite.operation.clear + + + + + + +

2d.composite.operation.clear

+

+ + +

Actual output:

+

FAIL (fallback content)

+ + + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.darker.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.darker.html new file mode 100644 index 000000000..ac155ab04 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.darker.html @@ -0,0 +1,29 @@ + + +Canvas test: 2d.composite.operation.darker + + + + + + +

2d.composite.operation.darker

+

+ + +

Actual output:

+

FAIL (fallback content)

+ + + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.default.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.default.html new file mode 100644 index 000000000..165e8b833 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.default.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.composite.operation.default + + + + + + +

2d.composite.operation.default

+

+ + +

Actual output:

+

FAIL (fallback content)

+ + + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.get.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.get.html new file mode 100644 index 000000000..53762dafe --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.get.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.composite.operation.get + + + + + + +

2d.composite.operation.get

+

+ + +

Actual output:

+

FAIL (fallback content)

+ + + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.highlight.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.highlight.html new file mode 100644 index 000000000..8a3bcf753 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.highlight.html @@ -0,0 +1,29 @@ + + +Canvas test: 2d.composite.operation.highlight + + + + + + +

2d.composite.operation.highlight

+

+ + +

Actual output:

+

FAIL (fallback content)

+ + + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.nullsuffix.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.nullsuffix.html new file mode 100644 index 000000000..aa3f8ccd5 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.nullsuffix.html @@ -0,0 +1,29 @@ + + +Canvas test: 2d.composite.operation.nullsuffix + + + + + + +

2d.composite.operation.nullsuffix

+

+ + +

Actual output:

+

FAIL (fallback content)

+ + + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.over.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.over.html new file mode 100644 index 000000000..e9b91e83d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.over.html @@ -0,0 +1,29 @@ + + +Canvas test: 2d.composite.operation.over + + + + + + +

2d.composite.operation.over

+

+ + +

Actual output:

+

FAIL (fallback content)

+ + + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.unrecognised.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.unrecognised.html new file mode 100644 index 000000000..ced2accc4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.operation.unrecognised.html @@ -0,0 +1,29 @@ + + +Canvas test: 2d.composite.operation.unrecognised + + + + + + +

2d.composite.operation.unrecognised

+

+ + +

Actual output:

+

FAIL (fallback content)

+ + + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.copy.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.copy.html new file mode 100644 index 000000000..8bf99f3f8 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.copy.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.solid.copy + + + + + + +

2d.composite.solid.copy

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.copy.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.copy.png new file mode 100644 index 000000000..fc0883e74 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.copy.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-atop.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-atop.html new file mode 100644 index 000000000..045caaa02 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-atop.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.solid.destination-atop + + + + + + +

2d.composite.solid.destination-atop

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-atop.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-atop.png new file mode 100644 index 000000000..dd04072ba Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-atop.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-in.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-in.html new file mode 100644 index 000000000..ec27d60b4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-in.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.solid.destination-in + + + + + + +

2d.composite.solid.destination-in

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-in.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-in.png new file mode 100644 index 000000000..dd04072ba Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-in.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-out.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-out.html new file mode 100644 index 000000000..d96ce76ca --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-out.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.solid.destination-out + + + + + + +

2d.composite.solid.destination-out

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-out.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-out.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-out.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-over.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-over.html new file mode 100644 index 000000000..08a02387d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-over.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.solid.destination-over + + + + + + +

2d.composite.solid.destination-over

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-over.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-over.png new file mode 100644 index 000000000..dd04072ba Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.destination-over.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.lighter.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.lighter.html new file mode 100644 index 000000000..0ffdcbb0f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.lighter.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.solid.lighter + + + + + + +

2d.composite.solid.lighter

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.lighter.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.lighter.png new file mode 100644 index 000000000..bf48767a8 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.lighter.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-atop.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-atop.html new file mode 100644 index 000000000..a122e437d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-atop.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.solid.source-atop + + + + + + +

2d.composite.solid.source-atop

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-atop.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-atop.png new file mode 100644 index 000000000..fc0883e74 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-atop.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-in.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-in.html new file mode 100644 index 000000000..ae3124ffa --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-in.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.solid.source-in + + + + + + +

2d.composite.solid.source-in

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-in.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-in.png new file mode 100644 index 000000000..fc0883e74 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-in.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-out.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-out.html new file mode 100644 index 000000000..8ea16796c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-out.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.solid.source-out + + + + + + +

2d.composite.solid.source-out

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-out.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-out.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-out.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-over.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-over.html new file mode 100644 index 000000000..e038d557b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-over.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.solid.source-over + + + + + + +

2d.composite.solid.source-over

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-over.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-over.png new file mode 100644 index 000000000..fc0883e74 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.source-over.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.xor.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.xor.html new file mode 100644 index 000000000..a7b4e821e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.xor.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.solid.xor + + + + + + +

2d.composite.solid.xor

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.xor.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.xor.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.solid.xor.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.copy.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.copy.html new file mode 100644 index 000000000..ede88859e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.copy.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.transparent.copy + + + + + + +

2d.composite.transparent.copy

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.copy.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.copy.png new file mode 100644 index 000000000..170e88183 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.copy.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-atop.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-atop.html new file mode 100644 index 000000000..350fe2be3 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-atop.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.transparent.destination-atop + + + + + + +

2d.composite.transparent.destination-atop

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-atop.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-atop.png new file mode 100644 index 000000000..57bbf64ac Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-atop.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-in.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-in.html new file mode 100644 index 000000000..b2e907d2a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-in.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.transparent.destination-in + + + + + + +

2d.composite.transparent.destination-in

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-in.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-in.png new file mode 100644 index 000000000..c6895de98 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-in.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-out.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-out.html new file mode 100644 index 000000000..aca47b8bd --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-out.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.transparent.destination-out + + + + + + +

2d.composite.transparent.destination-out

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-out.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-out.png new file mode 100644 index 000000000..873a9c45d Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-out.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-over.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-over.html new file mode 100644 index 000000000..676278df7 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-over.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.transparent.destination-over + + + + + + +

2d.composite.transparent.destination-over

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-over.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-over.png new file mode 100644 index 000000000..c0f0326d2 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.destination-over.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.lighter.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.lighter.html new file mode 100644 index 000000000..9aba34c48 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.lighter.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.transparent.lighter + + + + + + +

2d.composite.transparent.lighter

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.lighter.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.lighter.png new file mode 100644 index 000000000..bcb8ab408 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.lighter.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-atop.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-atop.html new file mode 100644 index 000000000..18229d6ae --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-atop.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.transparent.source-atop + + + + + + +

2d.composite.transparent.source-atop

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-atop.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-atop.png new file mode 100644 index 000000000..e0afff6b0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-atop.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-in.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-in.html new file mode 100644 index 000000000..57124d886 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-in.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.transparent.source-in + + + + + + +

2d.composite.transparent.source-in

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-in.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-in.png new file mode 100644 index 000000000..1459b5e54 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-in.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-out.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-out.html new file mode 100644 index 000000000..9b4b9d309 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-out.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.transparent.source-out + + + + + + +

2d.composite.transparent.source-out

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-out.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-out.png new file mode 100644 index 000000000..1459b5e54 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-out.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-over.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-over.html new file mode 100644 index 000000000..6299e8c8e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-over.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.transparent.source-over + + + + + + +

2d.composite.transparent.source-over

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-over.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-over.png new file mode 100644 index 000000000..c92cd9563 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.source-over.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.xor.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.xor.html new file mode 100644 index 000000000..b53d14048 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.xor.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.transparent.xor + + + + + + +

2d.composite.transparent.xor

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.xor.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.xor.png new file mode 100644 index 000000000..e0afff6b0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.transparent.xor.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.copy.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.copy.html new file mode 100644 index 000000000..966d7265d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.copy.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.composite.uncovered.fill.copy + + + + + + +

2d.composite.uncovered.fill.copy

+

fill() draws pixels not covered by the source object as (0,0,0,0), and does not leave the pixels unchanged.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.copy.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.copy.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.copy.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.destination-atop.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.destination-atop.html new file mode 100644 index 000000000..8ffc8db3f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.destination-atop.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.composite.uncovered.fill.destination-atop + + + + + + +

2d.composite.uncovered.fill.destination-atop

+

fill() draws pixels not covered by the source object as (0,0,0,0), and does not leave the pixels unchanged.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.destination-atop.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.destination-atop.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.destination-atop.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.destination-in.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.destination-in.html new file mode 100644 index 000000000..040fdf351 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.destination-in.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.composite.uncovered.fill.destination-in + + + + + + +

2d.composite.uncovered.fill.destination-in

+

fill() draws pixels not covered by the source object as (0,0,0,0), and does not leave the pixels unchanged.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.destination-in.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.destination-in.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.destination-in.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.source-in.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.source-in.html new file mode 100644 index 000000000..4d64f9094 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.source-in.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.composite.uncovered.fill.source-in + + + + + + +

2d.composite.uncovered.fill.source-in

+

fill() draws pixels not covered by the source object as (0,0,0,0), and does not leave the pixels unchanged.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.source-in.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.source-in.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.source-in.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.source-out.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.source-out.html new file mode 100644 index 000000000..d1f39baff --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.source-out.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.composite.uncovered.fill.source-out + + + + + + +

2d.composite.uncovered.fill.source-out

+

fill() draws pixels not covered by the source object as (0,0,0,0), and does not leave the pixels unchanged.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.source-out.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.source-out.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.fill.source-out.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.copy.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.copy.html new file mode 100644 index 000000000..43e070dc3 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.copy.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.composite.uncovered.image.copy + + + + + + +

2d.composite.uncovered.image.copy

+

drawImage() draws pixels not covered by the source object as (0,0,0,0), and does not leave the pixels unchanged.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.copy.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.copy.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.copy.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.destination-atop.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.destination-atop.html new file mode 100644 index 000000000..e59e8aa89 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.destination-atop.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.composite.uncovered.image.destination-atop + + + + + + +

2d.composite.uncovered.image.destination-atop

+

drawImage() draws pixels not covered by the source object as (0,0,0,0), and does not leave the pixels unchanged.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.destination-atop.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.destination-atop.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.destination-atop.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.destination-in.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.destination-in.html new file mode 100644 index 000000000..2872fd236 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.destination-in.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.composite.uncovered.image.destination-in + + + + + + +

2d.composite.uncovered.image.destination-in

+

drawImage() draws pixels not covered by the source object as (0,0,0,0), and does not leave the pixels unchanged.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.destination-in.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.destination-in.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.destination-in.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.source-in.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.source-in.html new file mode 100644 index 000000000..234e92472 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.source-in.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.composite.uncovered.image.source-in + + + + + + +

2d.composite.uncovered.image.source-in

+

drawImage() draws pixels not covered by the source object as (0,0,0,0), and does not leave the pixels unchanged.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.source-in.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.source-in.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.source-in.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.source-out.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.source-out.html new file mode 100644 index 000000000..4ab233a48 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.source-out.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.composite.uncovered.image.source-out + + + + + + +

2d.composite.uncovered.image.source-out

+

drawImage() draws pixels not covered by the source object as (0,0,0,0), and does not leave the pixels unchanged.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.source-out.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.source-out.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.image.source-out.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.copy.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.copy.html new file mode 100644 index 000000000..68a936692 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.copy.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.uncovered.nocontext.copy + + + + + + +

2d.composite.uncovered.nocontext.copy

+

drawImage() of a canvas with no context draws pixels as (0,0,0,0), and does not leave the pixels unchanged.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.copy.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.copy.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.copy.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.destination-atop.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.destination-atop.html new file mode 100644 index 000000000..ad11e21d9 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.destination-atop.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.uncovered.nocontext.destination-atop + + + + + + +

2d.composite.uncovered.nocontext.destination-atop

+

drawImage() of a canvas with no context draws pixels as (0,0,0,0), and does not leave the pixels unchanged.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.destination-atop.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.destination-atop.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.destination-atop.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.destination-in.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.destination-in.html new file mode 100644 index 000000000..0412a7aa3 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.destination-in.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.uncovered.nocontext.destination-in + + + + + + +

2d.composite.uncovered.nocontext.destination-in

+

drawImage() of a canvas with no context draws pixels as (0,0,0,0), and does not leave the pixels unchanged.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.destination-in.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.destination-in.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.destination-in.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.source-in.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.source-in.html new file mode 100644 index 000000000..d6136630e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.source-in.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.uncovered.nocontext.source-in + + + + + + +

2d.composite.uncovered.nocontext.source-in

+

drawImage() of a canvas with no context draws pixels as (0,0,0,0), and does not leave the pixels unchanged.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.source-in.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.source-in.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.source-in.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.source-out.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.source-out.html new file mode 100644 index 000000000..be5d6bf12 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.source-out.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.composite.uncovered.nocontext.source-out + + + + + + +

2d.composite.uncovered.nocontext.source-out

+

drawImage() of a canvas with no context draws pixels as (0,0,0,0), and does not leave the pixels unchanged.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.source-out.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.source-out.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.nocontext.source-out.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.copy.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.copy.html new file mode 100644 index 000000000..8c38388c2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.copy.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.composite.uncovered.pattern.copy + + + + + + +

2d.composite.uncovered.pattern.copy

+

Pattern fill() draws pixels not covered by the source object as (0,0,0,0), and does not leave the pixels unchanged.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.copy.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.copy.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.copy.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.destination-atop.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.destination-atop.html new file mode 100644 index 000000000..7ad35f48d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.destination-atop.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.composite.uncovered.pattern.destination-atop + + + + + + +

2d.composite.uncovered.pattern.destination-atop

+

Pattern fill() draws pixels not covered by the source object as (0,0,0,0), and does not leave the pixels unchanged.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.destination-atop.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.destination-atop.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.destination-atop.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.destination-in.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.destination-in.html new file mode 100644 index 000000000..085851c91 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.destination-in.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.composite.uncovered.pattern.destination-in + + + + + + +

2d.composite.uncovered.pattern.destination-in

+

Pattern fill() draws pixels not covered by the source object as (0,0,0,0), and does not leave the pixels unchanged.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.destination-in.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.destination-in.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.destination-in.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.source-in.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.source-in.html new file mode 100644 index 000000000..7e0b8795c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.source-in.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.composite.uncovered.pattern.source-in + + + + + + +

2d.composite.uncovered.pattern.source-in

+

Pattern fill() draws pixels not covered by the source object as (0,0,0,0), and does not leave the pixels unchanged.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.source-in.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.source-in.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.source-in.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.source-out.html b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.source-out.html new file mode 100644 index 000000000..0d34f693c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.source-out.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.composite.uncovered.pattern.source-out + + + + + + +

2d.composite.uncovered.pattern.source-out

+

Pattern fill() draws pixels not covered by the source object as (0,0,0,0), and does not leave the pixels unchanged.

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.source-out.png b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.source-out.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/compositing/2d.composite.uncovered.pattern.source-out.png differ diff --git a/testing/web-platform/tests/2dcontext/compositing/canvas_compositing_globalcompositeoperation_001-ref.htm b/testing/web-platform/tests/2dcontext/compositing/canvas_compositing_globalcompositeoperation_001-ref.htm new file mode 100644 index 000000000..70196fb36 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/canvas_compositing_globalcompositeoperation_001-ref.htm @@ -0,0 +1,11 @@ + + + + HTML5 Canvas Test: globalCompositeOperation "destination-over" + + + +

Description: If the globalCompositeOperation is set to "destination-over", display the destination image wherever the destination image is opaque.

+
black rectangle
+ + diff --git a/testing/web-platform/tests/2dcontext/compositing/canvas_compositing_globalcompositeoperation_001.htm b/testing/web-platform/tests/2dcontext/compositing/canvas_compositing_globalcompositeoperation_001.htm new file mode 100644 index 000000000..8d6208eb3 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/compositing/canvas_compositing_globalcompositeoperation_001.htm @@ -0,0 +1,32 @@ + + + + HTML5 Canvas Test: globalCompositeOperation "destination-over" + + + + + + + +

Description: If the globalCompositeOperation is set to "destination-over", display the destination image wherever the destination image is opaque.

+ Browser does not support HTML5 Canvas. + + diff --git a/testing/web-platform/tests/2dcontext/conformance-requirements/.gitkeep b/testing/web-platform/tests/2dcontext/conformance-requirements/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/testing/web-platform/tests/2dcontext/conformance-requirements/2d.coordinatespace-manual.html b/testing/web-platform/tests/2dcontext/conformance-requirements/2d.coordinatespace-manual.html new file mode 100644 index 000000000..ba925df1b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/conformance-requirements/2d.coordinatespace-manual.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.coordinatespace + + + + + + +

2d.coordinatespace

+

Coordinate space goes from top-left to bottom-right

+ +

This should not be upside down. +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/conformance-requirements/2d.coordinatespace.png b/testing/web-platform/tests/2dcontext/conformance-requirements/2d.coordinatespace.png new file mode 100644 index 000000000..8f8705c14 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/conformance-requirements/2d.coordinatespace.png differ diff --git a/testing/web-platform/tests/2dcontext/conformance-requirements/2d.missingargs.html b/testing/web-platform/tests/2dcontext/conformance-requirements/2d.missingargs.html new file mode 100644 index 000000000..2c89cf2ac --- /dev/null +++ b/testing/web-platform/tests/2dcontext/conformance-requirements/2d.missingargs.html @@ -0,0 +1,142 @@ + + +Canvas test: 2d.missingargs + + + + + + +

2d.missingargs

+

Missing arguments cause TypeError

+ + +

Actual output:

+

FAIL (fallback content)

+ + + + diff --git a/testing/web-platform/tests/2dcontext/conformance-requirements/2d.type.delete.html b/testing/web-platform/tests/2dcontext/conformance-requirements/2d.type.delete.html new file mode 100644 index 000000000..4097c35dd --- /dev/null +++ b/testing/web-platform/tests/2dcontext/conformance-requirements/2d.type.delete.html @@ -0,0 +1,29 @@ + + +Canvas test: 2d.type.delete + + + + + + +

2d.type.delete

+

window.CanvasRenderingContext2D is Configurable

+ +

Defined in "Web IDL" (draft) +

Actual output:

+

FAIL (fallback content)

+ + + + diff --git a/testing/web-platform/tests/2dcontext/conformance-requirements/2d.voidreturn.html b/testing/web-platform/tests/2dcontext/conformance-requirements/2d.voidreturn.html new file mode 100644 index 000000000..b23595c17 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/conformance-requirements/2d.voidreturn.html @@ -0,0 +1,63 @@ + + +Canvas test: 2d.voidreturn + + + + + + +

2d.voidreturn

+

void methods return undefined

+ +

Defined in "Web IDL" (draft) +

Actual output:

+

FAIL (fallback content)

+ + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/.gitkeep b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.3arg.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.3arg.html new file mode 100644 index 000000000..b4fd347b9 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.3arg.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.drawImage.3arg + + + + + + +

2d.drawImage.3arg

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.5arg.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.5arg.html new file mode 100644 index 000000000..b2075a607 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.5arg.html @@ -0,0 +1,39 @@ + + +Canvas test: 2d.drawImage.5arg + + + + + + +

2d.drawImage.5arg

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.9arg.basic.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.9arg.basic.html new file mode 100644 index 000000000..8ccecae22 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.9arg.basic.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.drawImage.9arg.basic + + + + + + +

2d.drawImage.9arg.basic

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.9arg.destpos.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.9arg.destpos.html new file mode 100644 index 000000000..e71d1ab4d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.9arg.destpos.html @@ -0,0 +1,39 @@ + + +Canvas test: 2d.drawImage.9arg.destpos + + + + + + +

2d.drawImage.9arg.destpos

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.9arg.destsize.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.9arg.destsize.html new file mode 100644 index 000000000..a76e0baa3 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.9arg.destsize.html @@ -0,0 +1,39 @@ + + +Canvas test: 2d.drawImage.9arg.destsize + + + + + + +

2d.drawImage.9arg.destsize

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.9arg.sourcepos.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.9arg.sourcepos.html new file mode 100644 index 000000000..34785c757 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.9arg.sourcepos.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.drawImage.9arg.sourcepos + + + + + + +

2d.drawImage.9arg.sourcepos

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.9arg.sourcesize.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.9arg.sourcesize.html new file mode 100644 index 000000000..a640605b1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.9arg.sourcesize.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.drawImage.9arg.sourcesize + + + + + + +

2d.drawImage.9arg.sourcesize

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.alpha.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.alpha.html new file mode 100644 index 000000000..8056c96d3 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.alpha.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.drawImage.alpha + + + + + + +

2d.drawImage.alpha

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.animated.apng.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.animated.apng.html new file mode 100644 index 000000000..bdc64462c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.animated.apng.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.drawImage.animated.apng + + + + + + +

2d.drawImage.animated.apng

+

drawImage() of an APNG with no poster frame draws the first frame

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.animated.gif.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.animated.gif.html new file mode 100644 index 000000000..3cf5e0fb8 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.animated.gif.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.drawImage.animated.gif + + + + + + +

2d.drawImage.animated.gif

+

drawImage() of an animated GIF draws the first frame

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.animated.poster.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.animated.poster.html new file mode 100644 index 000000000..b0c76c1e5 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.animated.poster.html @@ -0,0 +1,29 @@ + + +Canvas test: 2d.drawImage.animated.poster + + + + + + +

2d.drawImage.animated.poster

+

drawImage() of an APNG draws the poster frame

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.broken.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.broken.html new file mode 100644 index 000000000..f56ece4d0 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.broken.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.drawImage.broken + + + + + + +

2d.drawImage.broken

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.canvas.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.canvas.html new file mode 100644 index 000000000..7ae961404 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.canvas.html @@ -0,0 +1,40 @@ + + +Canvas test: 2d.drawImage.canvas + + + + + + +

2d.drawImage.canvas

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.clip.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.clip.html new file mode 100644 index 000000000..fbf86e11c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.clip.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.drawImage.clip + + + + + + +

2d.drawImage.clip

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.composite.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.composite.html new file mode 100644 index 000000000..e4175312b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.composite.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.drawImage.composite + + + + + + +

2d.drawImage.composite

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.floatsource.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.floatsource.html new file mode 100644 index 000000000..689b1f8ae --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.floatsource.html @@ -0,0 +1,29 @@ + + +Canvas test: 2d.drawImage.floatsource + + + + + + +

2d.drawImage.floatsource

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.incomplete.emptysrc.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.incomplete.emptysrc.html new file mode 100644 index 000000000..132e492c9 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.incomplete.emptysrc.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.drawImage.incomplete.emptysrc + + + + + + +

2d.drawImage.incomplete.emptysrc

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.incomplete.immediate.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.incomplete.immediate.html new file mode 100644 index 000000000..1ff5ab2c4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.incomplete.immediate.html @@ -0,0 +1,37 @@ + + +Canvas test: 2d.drawImage.incomplete.immediate + + + + + + +

2d.drawImage.incomplete.immediate

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.incomplete.nosrc.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.incomplete.nosrc.html new file mode 100644 index 000000000..5067b7a5c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.incomplete.nosrc.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.drawImage.incomplete.nosrc + + + + + + +

2d.drawImage.incomplete.nosrc

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.incomplete.reload.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.incomplete.reload.html new file mode 100644 index 000000000..efd41c938 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.incomplete.reload.html @@ -0,0 +1,39 @@ + + +Canvas test: 2d.drawImage.incomplete.reload + + + + + + +

2d.drawImage.incomplete.reload

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.incomplete.removedsrc.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.incomplete.removedsrc.html new file mode 100644 index 000000000..a744d591d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.incomplete.removedsrc.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.drawImage.incomplete.removedsrc + + + + + + +

2d.drawImage.incomplete.removedsrc

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.negativedest.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.negativedest.html new file mode 100644 index 000000000..2d2c15849 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.negativedest.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.drawImage.negativedest + + + + + + +

2d.drawImage.negativedest

+

Negative destination width/height represents the correct rectangle

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.negativedir.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.negativedir.html new file mode 100644 index 000000000..a333f8fb9 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.negativedir.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.drawImage.negativedir + + + + + + +

2d.drawImage.negativedir

+

Negative dimensions do not affect the direction of the image

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.negativesource.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.negativesource.html new file mode 100644 index 000000000..af377ffdf --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.negativesource.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.drawImage.negativesource + + + + + + +

2d.drawImage.negativesource

+

Negative source width/height represents the correct rectangle

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.nonfinite.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.nonfinite.html new file mode 100644 index 000000000..14e634a62 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.nonfinite.html @@ -0,0 +1,332 @@ + + +Canvas test: 2d.drawImage.nonfinite + + + + + + +

2d.drawImage.nonfinite

+

drawImage() with Infinity/NaN is ignored

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.nowrap.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.nowrap.html new file mode 100644 index 000000000..8b0fa4890 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.nowrap.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.drawImage.nowrap + + + + + + +

2d.drawImage.nowrap

+

Stretched images do not get pixels wrapping around the edges

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.null.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.null.html new file mode 100644 index 000000000..f4ce00e56 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.null.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.drawImage.null + + + + + + +

2d.drawImage.null

+

+ + +

Actual output:

+

FAIL (fallback content)

+ + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.path.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.path.html new file mode 100644 index 000000000..2e389ebd4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.path.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.drawImage.path + + + + + + +

2d.drawImage.path

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.self.1.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.self.1.html new file mode 100644 index 000000000..8f05c1445 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.self.1.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.drawImage.self.1 + + + + + + +

2d.drawImage.self.1

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.self.2.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.self.2.html new file mode 100644 index 000000000..4fc1319fc --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.self.2.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.drawImage.self.2 + + + + + + +

2d.drawImage.self.2

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.svg.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.svg.html new file mode 100644 index 000000000..5935eb864 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.svg.html @@ -0,0 +1,29 @@ + + +Canvas test: 2d.drawImage.svg + + + + + + +

2d.drawImage.svg

+

drawImage() of an SVG image

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.transform.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.transform.html new file mode 100644 index 000000000..ab3c09a22 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.transform.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.drawImage.transform + + + + + + +

2d.drawImage.transform

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.wrongtype.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.wrongtype.html new file mode 100644 index 000000000..cd2a7fc5b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.wrongtype.html @@ -0,0 +1,30 @@ + + +Canvas test: 2d.drawImage.wrongtype + + + + + + +

2d.drawImage.wrongtype

+

Incorrect image types in drawImage do not match any defined overloads, so WebIDL throws a TypeError

+ +

Defined in "Web IDL" (draft) +

Actual output:

+

FAIL (fallback content)

+ + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.zerocanvas.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.zerocanvas.html new file mode 100644 index 000000000..e14f5d3b3 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.zerocanvas.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.drawImage.zerocanvas + + + + + + +

2d.drawImage.zerocanvas

+

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.zerosource.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.zerosource.html new file mode 100644 index 000000000..6906284e0 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.zerosource.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.drawImage.zerosource + + + + + + +

2d.drawImage.zerosource

+

drawImage with zero-sized source rectangle throws INDEX_SIZE_ERR

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.zerosource.image.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.zerosource.image.html new file mode 100644 index 000000000..cda752c31 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/2d.drawImage.zerosource.image.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.drawImage.zerosource.image + + + + + + +

2d.drawImage.zerosource.image

+

drawImage with zero-sized source rectangle from image throws INDEX_SIZE_ERR

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

+ + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_1.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_1.html new file mode 100644 index 000000000..871e279ac --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_1.html @@ -0,0 +1,34 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_10.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_10.html new file mode 100644 index 000000000..14e15ffc3 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_10.html @@ -0,0 +1,38 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_10_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_10_ref.html new file mode 100644 index 000000000..cd05233b8 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_10_ref.html @@ -0,0 +1,26 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_11.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_11.html new file mode 100644 index 000000000..e06dfc0df --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_11.html @@ -0,0 +1,36 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_11_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_11_ref.html new file mode 100644 index 000000000..970f626df --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_11_ref.html @@ -0,0 +1,26 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_12.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_12.html new file mode 100644 index 000000000..47debc796 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_12.html @@ -0,0 +1,36 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_12_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_12_ref.html new file mode 100644 index 000000000..190f74f93 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_12_ref.html @@ -0,0 +1,26 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_1_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_1_ref.html new file mode 100644 index 000000000..d0bac45ed --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_1_ref.html @@ -0,0 +1,31 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_2.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_2.html new file mode 100644 index 000000000..b169d3743 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_2.html @@ -0,0 +1,35 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_2_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_2_ref.html new file mode 100644 index 000000000..72ec289f7 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_2_ref.html @@ -0,0 +1,31 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_3.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_3.html new file mode 100644 index 000000000..e59e5d352 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_3.html @@ -0,0 +1,36 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_3_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_3_ref.html new file mode 100644 index 000000000..3e153f1ca --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_3_ref.html @@ -0,0 +1,31 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_4.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_4.html new file mode 100644 index 000000000..f3dd84e2a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_4.html @@ -0,0 +1,37 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_4_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_4_ref.html new file mode 100644 index 000000000..9a8cc9937 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_4_ref.html @@ -0,0 +1,26 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_5.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_5.html new file mode 100644 index 000000000..2190847f8 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_5.html @@ -0,0 +1,36 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_5_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_5_ref.html new file mode 100644 index 000000000..47dd63ee2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_5_ref.html @@ -0,0 +1,26 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_6.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_6.html new file mode 100644 index 000000000..2ce48d8fa --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_6.html @@ -0,0 +1,36 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_6_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_6_ref.html new file mode 100644 index 000000000..190f74f93 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_6_ref.html @@ -0,0 +1,26 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_7.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_7.html new file mode 100644 index 000000000..195290921 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_7.html @@ -0,0 +1,36 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_7_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_7_ref.html new file mode 100644 index 000000000..51b2b276c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_7_ref.html @@ -0,0 +1,26 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_8.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_8.html new file mode 100644 index 000000000..c47a5b55c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_8.html @@ -0,0 +1,36 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_8_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_8_ref.html new file mode 100644 index 000000000..652bf6eb9 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_8_ref.html @@ -0,0 +1,26 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_9.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_9.html new file mode 100644 index 000000000..8b48e644f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_9.html @@ -0,0 +1,43 @@ + + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_9_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_9_ref.html new file mode 100644 index 000000000..b9be7e514 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_canvas_9_ref.html @@ -0,0 +1,22 @@ + + + + + + + + + + + \ No newline at end of file diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_1.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_1.html new file mode 100644 index 000000000..b9de85a97 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_1.html @@ -0,0 +1,30 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_10.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_10.html new file mode 100644 index 000000000..3b11b730f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_10.html @@ -0,0 +1,34 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_10_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_10_ref.html new file mode 100644 index 000000000..60545df17 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_10_ref.html @@ -0,0 +1,19 @@ + + + + + + + +
+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_11.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_11.html new file mode 100644 index 000000000..dd1a6149b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_11.html @@ -0,0 +1,32 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_11_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_11_ref.html new file mode 100644 index 000000000..10d8885f2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_11_ref.html @@ -0,0 +1,19 @@ + + + + + + + +
+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_12.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_12.html new file mode 100644 index 000000000..402a661f9 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_12.html @@ -0,0 +1,32 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_12_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_12_ref.html new file mode 100644 index 000000000..5f6f22111 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_12_ref.html @@ -0,0 +1,32 @@ + + + + + + + +
+
+
+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_13.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_13.html new file mode 100644 index 000000000..1faecc325 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_13.html @@ -0,0 +1,38 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_13_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_13_ref.html new file mode 100644 index 000000000..9ac306a5c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_13_ref.html @@ -0,0 +1,20 @@ + + + + + + + +
+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_1_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_1_ref.html new file mode 100644 index 000000000..60545df17 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_1_ref.html @@ -0,0 +1,19 @@ + + + + + + + +
+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_2.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_2.html new file mode 100644 index 000000000..e20ea97e2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_2.html @@ -0,0 +1,31 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_2_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_2_ref.html new file mode 100644 index 000000000..c45352835 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_2_ref.html @@ -0,0 +1,23 @@ + + + + + + + +
+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_3.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_3.html new file mode 100644 index 000000000..e09c2ab00 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_3.html @@ -0,0 +1,31 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_3_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_3_ref.html new file mode 100644 index 000000000..b72687a8a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_3_ref.html @@ -0,0 +1,23 @@ + + + + + + + +
+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_4.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_4.html new file mode 100644 index 000000000..7f029ab0a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_4.html @@ -0,0 +1,32 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_4_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_4_ref.html new file mode 100644 index 000000000..baa6591a2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_4_ref.html @@ -0,0 +1,29 @@ + + + + + + + +
+ +
+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_5.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_5.html new file mode 100644 index 000000000..d221176ad --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_5.html @@ -0,0 +1,31 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_5_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_5_ref.html new file mode 100644 index 000000000..66b7cc194 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_5_ref.html @@ -0,0 +1,39 @@ + + + + + + + +
+
+ +
+
+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_6.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_6.html new file mode 100644 index 000000000..a32162a46 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_6.html @@ -0,0 +1,32 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_6_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_6_ref.html new file mode 100644 index 000000000..d73433755 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_6_ref.html @@ -0,0 +1,25 @@ + + + + + + + +
+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_7.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_7.html new file mode 100644 index 000000000..b902df0c2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_7.html @@ -0,0 +1,32 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_7_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_7_ref.html new file mode 100644 index 000000000..e823ffbb7 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_7_ref.html @@ -0,0 +1,35 @@ + + + + + + + +
+
+
+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_8.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_8.html new file mode 100644 index 000000000..9b2301e29 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_8.html @@ -0,0 +1,32 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_8_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_8_ref.html new file mode 100644 index 000000000..1a025d26d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_8_ref.html @@ -0,0 +1,35 @@ + + + + + + + +
+
+
+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_9.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_9.html new file mode 100644 index 000000000..73a872f0c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_9.html @@ -0,0 +1,37 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_9_ref.html b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_9_ref.html new file mode 100644 index 000000000..5341e05c1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-images-to-the-canvas/drawimage_html_image_9_ref.html @@ -0,0 +1,19 @@ + + + + + + + +
+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-model/.gitkeep b/testing/web-platform/tests/2dcontext/drawing-model/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/.gitkeep b/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/canvas_complexshapes_ispointInpath_001.htm b/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/canvas_complexshapes_ispointInpath_001.htm new file mode 100644 index 000000000..18c3c9afb --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/canvas_complexshapes_ispointInpath_001.htm @@ -0,0 +1,31 @@ + + + + HTML5 Canvas Test: isPointInPath() unaffected by the current transformation matrix + + + + + + + + +

Description: isPointInPath must check the point (x, y) as coordinates unaffected by the current transformation matrix.

+ Browser does not support HTML5 Canvas. + + diff --git a/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/canvas_focus_drawCustomFocusRing_001.html b/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/canvas_focus_drawCustomFocusRing_001.html new file mode 100644 index 000000000..56d5ebb51 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/canvas_focus_drawCustomFocusRing_001.html @@ -0,0 +1,41 @@ + + + + canvas drawCustomFocusRing() step1 test + + + + + + +

Description

+

This test checks whether drawCustomFocusRing returns false if the element passed as an argument is not focused or is not a descendant of the element with whose context the method is associated.

+
+
+ + +
+ + + diff --git a/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/canvas_focus_drawFocusIfNeeded_AAPI_001-manual.html b/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/canvas_focus_drawFocusIfNeeded_AAPI_001-manual.html new file mode 100644 index 000000000..bf38fa68b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/canvas_focus_drawFocusIfNeeded_AAPI_001-manual.html @@ -0,0 +1,50 @@ + + + + drawFocusIfNeeded() - AAPI test + + + + + +

Description

+

This manual test can be used to verify that drawFocusIfNeeded actually updates the accessible location information (i.e. UIAutomation's CurrentBoundingRectangle) in the Accessibility API. To perform this test, you will need an accessibility API inspector. To perform this test, use the tab key to move from the first focusable element to through to the fourth. This test passes if the first parameter of the bounding rectangle increases by 100 when focus is moved from the gray square to the orange square.

+

First focusable element

+ + Second focusable element + Third focusable element + +

Fourth focusable element

+ + + + \ No newline at end of file diff --git a/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/drawFocusIfNeeded_001.html b/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/drawFocusIfNeeded_001.html new file mode 100755 index 000000000..6daf32a2a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/drawFocusIfNeeded_001.html @@ -0,0 +1,66 @@ + + + + drawFocusIfNeeded() + + + + + + +

Description

+

This test uses drawFocusIfNeeded to draw a focus ring in the canvas, then compare the ImageData before and after the invocation of the method to check that the focus ring was actually drawn.

+
+

Before:

+ + +

After:

+ + + +
+ +
+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/drawFocusIfNeeded_002.html b/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/drawFocusIfNeeded_002.html new file mode 100755 index 000000000..ec0a4ef42 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/drawFocusIfNeeded_002.html @@ -0,0 +1,68 @@ + + + + drawFocusIfNeeded() + + + + + + +

Description

+

This test uses drawFocusIfNeeded does nothing if the element is not in focus but comparing ImageData from before and after.

+
+

Before:

+ + +

After:

+ + + +
+ +
+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/drawFocusIfNeeded_003.html b/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/drawFocusIfNeeded_003.html new file mode 100755 index 000000000..b62c0641f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/drawFocusIfNeeded_003.html @@ -0,0 +1,69 @@ + + + + drawFocusIfNeeded() + + + + + + +

Description

+

This test uses drawFocusIfNeeded does nothing if the element is not a descendant but comparing ImageData from before and after.

+
+

Before:

+ + + +

After:

+ + +
+ +
+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/drawFocusIfNeeded_004.html b/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/drawFocusIfNeeded_004.html new file mode 100755 index 000000000..326db0daa --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/drawFocusIfNeeded_004.html @@ -0,0 +1,88 @@ + + + + drawFocusIfNeeded() + + + + + + +

Description

+

This test uses drawFocusIfNeeded to draw a complex path focus then compare ImageData from before and after.

+
+

Before:

+ + +

After:

+ + + +
+ +
+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/drawFocusIfNeeded_005.html b/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/drawFocusIfNeeded_005.html new file mode 100755 index 000000000..96a4e3fd5 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-paths-to-the-canvas/drawFocusIfNeeded_005.html @@ -0,0 +1,88 @@ + + + + drawFocusIfNeeded() + + + + + + +

Description

+

This test uses drawFocusIfNeeded to draw a complex path focus then compare ImageData from before and after.

+
+

Before:

+ + +

After:

+ +

This is text.

+
+
+ +
+ + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/.gitkeep b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.basic.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.basic.html new file mode 100644 index 000000000..9ec16ed5b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.basic.html @@ -0,0 +1,30 @@ + + +Canvas test: 2d.clearRect.basic + + + + + + +

2d.clearRect.basic

+

clearRect clears to transparent black

+ + +

Actual output:

+

FAIL (fallback content)

+

Expected output:

+

    + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.clip.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.clip.html new file mode 100644 index 000000000..bd35e7f0c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.clip.html @@ -0,0 +1,39 @@ + + +Canvas test: 2d.clearRect.clip + + + + + + +

    2d.clearRect.clip

    +

    clearRect is affected by clipping regions

    + + +

    Actual output:

    +

    FAIL (fallback content)

    +

    Expected output:

    +

      + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.globalalpha.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.globalalpha.html new file mode 100644 index 000000000..34c64aec9 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.globalalpha.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.clearRect.globalalpha + + + + + + +

      2d.clearRect.globalalpha

      +

      clearRect is not affected by globalAlpha

      + + +

      Actual output:

      +

      FAIL (fallback content)

      +

      Expected output:

      +

        + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.globalcomposite.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.globalcomposite.html new file mode 100644 index 000000000..96830e1ea --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.globalcomposite.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.clearRect.globalcomposite + + + + + + +

        2d.clearRect.globalcomposite

        +

        clearRect is not affected by globalCompositeOperation

        + + +

        Actual output:

        +

        FAIL (fallback content)

        +

        Expected output:

        +

          + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.negative.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.negative.html new file mode 100644 index 000000000..2d1a0cb05 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.negative.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.clearRect.negative + + + + + + +

          2d.clearRect.negative

          +

          clearRect of negative sizes works

          + + +

          Actual output:

          +

          FAIL (fallback content)

          +

          Expected output:

          +

            + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.nonfinite.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.nonfinite.html new file mode 100644 index 000000000..35a3d79c1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.nonfinite.html @@ -0,0 +1,54 @@ + + +Canvas test: 2d.clearRect.nonfinite + + + + + + +

            2d.clearRect.nonfinite

            +

            clearRect() with Infinity/NaN is ignored

            + + +

            Actual output:

            +

            FAIL (fallback content)

            +

            Expected output:

            +

              + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.path.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.path.html new file mode 100644 index 000000000..c5429c8c2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.path.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.clearRect.path + + + + + + +

              2d.clearRect.path

              +

              clearRect does not affect the current path

              + + +

              Actual output:

              +

              FAIL (fallback content)

              +

              Expected output:

              +

                + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.shadow.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.shadow.html new file mode 100644 index 000000000..384baf9c7 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.shadow.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.clearRect.shadow + + + + + + +

                2d.clearRect.shadow

                +

                clearRect does not draw shadows

                + + +

                Actual output:

                +

                FAIL (fallback content)

                +

                Expected output:

                +

                  + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.transform.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.transform.html new file mode 100644 index 000000000..8ff20443c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.transform.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.clearRect.transform + + + + + + +

                  2d.clearRect.transform

                  +

                  clearRect is affected by transforms

                  + + +

                  Actual output:

                  +

                  FAIL (fallback content)

                  +

                  Expected output:

                  +

                    + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.zero.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.zero.html new file mode 100644 index 000000000..73805edd6 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.clearRect.zero.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.clearRect.zero + + + + + + +

                    2d.clearRect.zero

                    +

                    clearRect of zero pixels has no effect

                    + + +

                    Actual output:

                    +

                    FAIL (fallback content)

                    +

                    Expected output:

                    +

                      + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.basic.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.basic.html new file mode 100644 index 000000000..455c4b5b2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.basic.html @@ -0,0 +1,29 @@ + + +Canvas test: 2d.fillRect.basic + + + + + + +

                      2d.fillRect.basic

                      +

                      fillRect works

                      + + +

                      Actual output:

                      +

                      FAIL (fallback content)

                      +

                      Expected output:

                      +

                        + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.clip.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.clip.html new file mode 100644 index 000000000..efd2d8cbb --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.clip.html @@ -0,0 +1,40 @@ + + +Canvas test: 2d.fillRect.clip + + + + + + +

                        2d.fillRect.clip

                        +

                        fillRect is affected by clipping regions

                        + + +

                        Actual output:

                        +

                        FAIL (fallback content)

                        +

                        Expected output:

                        +

                          + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.negative.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.negative.html new file mode 100644 index 000000000..6e9427539 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.negative.html @@ -0,0 +1,37 @@ + + +Canvas test: 2d.fillRect.negative + + + + + + +

                          2d.fillRect.negative

                          +

                          fillRect of negative sizes works

                          + + +

                          Actual output:

                          +

                          FAIL (fallback content)

                          +

                          Expected output:

                          +

                            + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.nonfinite.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.nonfinite.html new file mode 100644 index 000000000..92bb8fbc0 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.nonfinite.html @@ -0,0 +1,55 @@ + + +Canvas test: 2d.fillRect.nonfinite + + + + + + +

                            2d.fillRect.nonfinite

                            +

                            fillRect() with Infinity/NaN is ignored

                            + + +

                            Actual output:

                            +

                            FAIL (fallback content)

                            +

                            Expected output:

                            +

                              + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.path.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.path.html new file mode 100644 index 000000000..b018cba44 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.path.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.fillRect.path + + + + + + +

                              2d.fillRect.path

                              +

                              fillRect does not affect the current path

                              + + +

                              Actual output:

                              +

                              FAIL (fallback content)

                              +

                              Expected output:

                              +

                                + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.shadow.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.shadow.html new file mode 100644 index 000000000..be8de26c4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.shadow.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.fillRect.shadow + + + + + + +

                                2d.fillRect.shadow

                                +

                                fillRect draws shadows

                                + + +

                                Actual output:

                                +

                                FAIL (fallback content)

                                +

                                Expected output:

                                +

                                  + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.transform.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.transform.html new file mode 100644 index 000000000..711b60201 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.transform.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillRect.transform + + + + + + +

                                  2d.fillRect.transform

                                  +

                                  fillRect is affected by transforms

                                  + + +

                                  Actual output:

                                  +

                                  FAIL (fallback content)

                                  +

                                  Expected output:

                                  +

                                    + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.zero.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.zero.html new file mode 100644 index 000000000..c6ea3ae02 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.fillRect.zero.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.fillRect.zero + + + + + + +

                                    2d.fillRect.zero

                                    +

                                    fillRect of zero pixels has no effect

                                    + + +

                                    Actual output:

                                    +

                                    FAIL (fallback content)

                                    +

                                    Expected output:

                                    +

                                      + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.basic.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.basic.html new file mode 100644 index 000000000..5a3af8b4c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.basic.html @@ -0,0 +1,30 @@ + + +Canvas test: 2d.strokeRect.basic + + + + + + +

                                      2d.strokeRect.basic

                                      +

                                      strokeRect works

                                      + + +

                                      Actual output:

                                      +

                                      FAIL (fallback content)

                                      +

                                      Expected output:

                                      +

                                        + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.clip.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.clip.html new file mode 100644 index 000000000..6ccb7da44 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.clip.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.strokeRect.clip + + + + + + +

                                        2d.strokeRect.clip

                                        +

                                        strokeRect is affected by clipping regions

                                        + + +

                                        Actual output:

                                        +

                                        FAIL (fallback content)

                                        +

                                        Expected output:

                                        +

                                          + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.globalalpha.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.globalalpha.html new file mode 100644 index 000000000..3e4cf0769 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.globalalpha.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.strokeRect.globalalpha + + + + + + +

                                          2d.strokeRect.globalalpha

                                          +

                                          strokeRect is affected by globalAlpha

                                          + + +

                                          Actual output:

                                          +

                                          FAIL (fallback content)

                                          +

                                          Expected output:

                                          +

                                            + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.globalcomposite.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.globalcomposite.html new file mode 100644 index 000000000..5239a03d4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.globalcomposite.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.strokeRect.globalcomposite + + + + + + +

                                            2d.strokeRect.globalcomposite

                                            +

                                            strokeRect is not affected by globalCompositeOperation

                                            + + +

                                            Actual output:

                                            +

                                            FAIL (fallback content)

                                            +

                                            Expected output:

                                            +

                                              + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.negative.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.negative.html new file mode 100644 index 000000000..1973d6625 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.negative.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.strokeRect.negative + + + + + + +

                                              2d.strokeRect.negative

                                              +

                                              strokeRect of negative sizes works

                                              + + +

                                              Actual output:

                                              +

                                              FAIL (fallback content)

                                              +

                                              Expected output:

                                              +

                                                + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.nonfinite.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.nonfinite.html new file mode 100644 index 000000000..ed4c3edce --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.nonfinite.html @@ -0,0 +1,56 @@ + + +Canvas test: 2d.strokeRect.nonfinite + + + + + + +

                                                2d.strokeRect.nonfinite

                                                +

                                                strokeRect() with Infinity/NaN is ignored

                                                + + +

                                                Actual output:

                                                +

                                                FAIL (fallback content)

                                                +

                                                Expected output:

                                                +

                                                  + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.path.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.path.html new file mode 100644 index 000000000..81e7d4362 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.path.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.strokeRect.path + + + + + + +

                                                  2d.strokeRect.path

                                                  +

                                                  strokeRect does not affect the current path

                                                  + + +

                                                  Actual output:

                                                  +

                                                  FAIL (fallback content)

                                                  +

                                                  Expected output:

                                                  +

                                                    + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.shadow.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.shadow.html new file mode 100644 index 000000000..26aaa0f5d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.shadow.html @@ -0,0 +1,37 @@ + + +Canvas test: 2d.strokeRect.shadow + + + + + + +

                                                    2d.strokeRect.shadow

                                                    +

                                                    strokeRect draws shadows

                                                    + + +

                                                    Actual output:

                                                    +

                                                    FAIL (fallback content)

                                                    +

                                                    Expected output:

                                                    +

                                                      + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.transform.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.transform.html new file mode 100644 index 000000000..c9a4a76d9 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.transform.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.strokeRect.transform + + + + + + +

                                                      2d.strokeRect.transform

                                                      +

                                                      fillRect is affected by transforms

                                                      + + +

                                                      Actual output:

                                                      +

                                                      FAIL (fallback content)

                                                      +

                                                      Expected output:

                                                      +

                                                        + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.zero.1.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.zero.1.html new file mode 100644 index 000000000..915c1252f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.zero.1.html @@ -0,0 +1,30 @@ + + +Canvas test: 2d.strokeRect.zero.1 + + + + + + +

                                                        2d.strokeRect.zero.1

                                                        +

                                                        strokeRect of 0x0 pixels draws nothing

                                                        + + +

                                                        Actual output:

                                                        +

                                                        FAIL (fallback content)

                                                        +

                                                        Expected output:

                                                        +

                                                          + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.zero.2.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.zero.2.html new file mode 100644 index 000000000..bec7bdd12 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.zero.2.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.strokeRect.zero.2 + + + + + + +

                                                          2d.strokeRect.zero.2

                                                          +

                                                          strokeRect of 0x0 pixels draws nothing, including caps and joins

                                                          + + +

                                                          Actual output:

                                                          +

                                                          FAIL (fallback content)

                                                          +

                                                          Expected output:

                                                          +

                                                            + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.zero.3.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.zero.3.html new file mode 100644 index 000000000..44232f5fd --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.zero.3.html @@ -0,0 +1,30 @@ + + +Canvas test: 2d.strokeRect.zero.3 + + + + + + +

                                                            2d.strokeRect.zero.3

                                                            +

                                                            strokeRect of Nx0 pixels draws a straight line

                                                            + + +

                                                            Actual output:

                                                            +

                                                            FAIL (fallback content)

                                                            +

                                                            Expected output:

                                                            +

                                                              + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.zero.4.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.zero.4.html new file mode 100644 index 000000000..3d5941478 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.zero.4.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.strokeRect.zero.4 + + + + + + +

                                                              2d.strokeRect.zero.4

                                                              +

                                                              strokeRect of Nx0 pixels draws a closed line with no caps

                                                              + + +

                                                              Actual output:

                                                              +

                                                              FAIL (fallback content)

                                                              +

                                                              Expected output:

                                                              +

                                                                + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.zero.5.html b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.zero.5.html new file mode 100644 index 000000000..3e8c7d4bf --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/2d.strokeRect.zero.5.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.strokeRect.zero.5 + + + + + + +

                                                                2d.strokeRect.zero.5

                                                                +

                                                                strokeRect of Nx0 pixels draws a closed line with joins

                                                                + + +

                                                                Actual output:

                                                                +

                                                                FAIL (fallback content)

                                                                +

                                                                Expected output:

                                                                +

                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/clear-100x50.png b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/clear-100x50.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/drawing-rectangles-to-the-canvas/clear-100x50.png differ diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/.gitkeep b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.center.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.center.html new file mode 100644 index 000000000..bcbdbd665 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.center.html @@ -0,0 +1,48 @@ + + +Canvas test: 2d.text.draw.align.center + + + + + + + +

                                                                  2d.text.draw.align.center

                                                                  +

                                                                  textAlign center is the center of the em squares (not the bounding box)

                                                                  + + +A +

                                                                  Actual output:

                                                                  +

                                                                  FAIL (fallback content)

                                                                  +

                                                                  Expected output:

                                                                  +

                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.end.ltr.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.end.ltr.html new file mode 100644 index 000000000..681085859 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.end.ltr.html @@ -0,0 +1,48 @@ + + +Canvas test: 2d.text.draw.align.end.ltr + + + + + + + +

                                                                    2d.text.draw.align.end.ltr

                                                                    +

                                                                    textAlign end with ltr is the right edge

                                                                    + + +A +

                                                                    Actual output:

                                                                    +

                                                                    FAIL (fallback content)

                                                                    +

                                                                    Expected output:

                                                                    +

                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.end.rtl.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.end.rtl.html new file mode 100644 index 000000000..1ccd2bccb --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.end.rtl.html @@ -0,0 +1,48 @@ + + +Canvas test: 2d.text.draw.align.end.rtl + + + + + + + +

                                                                      2d.text.draw.align.end.rtl

                                                                      +

                                                                      textAlign end with rtl is the left edge

                                                                      + + +A +

                                                                      Actual output:

                                                                      +

                                                                      FAIL (fallback content)

                                                                      +

                                                                      Expected output:

                                                                      +

                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.left.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.left.html new file mode 100644 index 000000000..5e7418e36 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.left.html @@ -0,0 +1,48 @@ + + +Canvas test: 2d.text.draw.align.left + + + + + + + +

                                                                        2d.text.draw.align.left

                                                                        +

                                                                        textAlign left is the left of the first em square (not the bounding box)

                                                                        + + +A +

                                                                        Actual output:

                                                                        +

                                                                        FAIL (fallback content)

                                                                        +

                                                                        Expected output:

                                                                        +

                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.right.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.right.html new file mode 100644 index 000000000..81e3acf36 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.right.html @@ -0,0 +1,48 @@ + + +Canvas test: 2d.text.draw.align.right + + + + + + + +

                                                                          2d.text.draw.align.right

                                                                          +

                                                                          textAlign right is the right of the last em square (not the bounding box)

                                                                          + + +A +

                                                                          Actual output:

                                                                          +

                                                                          FAIL (fallback content)

                                                                          +

                                                                          Expected output:

                                                                          +

                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.start.ltr.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.start.ltr.html new file mode 100644 index 000000000..f47ef78a7 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.start.ltr.html @@ -0,0 +1,48 @@ + + +Canvas test: 2d.text.draw.align.start.ltr + + + + + + + +

                                                                            2d.text.draw.align.start.ltr

                                                                            +

                                                                            textAlign start with ltr is the left edge

                                                                            + + +A +

                                                                            Actual output:

                                                                            +

                                                                            FAIL (fallback content)

                                                                            +

                                                                            Expected output:

                                                                            +

                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.start.rtl.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.start.rtl.html new file mode 100644 index 000000000..cc09b9e4d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.align.start.rtl.html @@ -0,0 +1,48 @@ + + +Canvas test: 2d.text.draw.align.start.rtl + + + + + + + +

                                                                              2d.text.draw.align.start.rtl

                                                                              +

                                                                              textAlign start with rtl is the right edge

                                                                              + + +A +

                                                                              Actual output:

                                                                              +

                                                                              FAIL (fallback content)

                                                                              +

                                                                              Expected output:

                                                                              +

                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.baseline.alphabetic.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.baseline.alphabetic.html new file mode 100644 index 000000000..bdb65ab90 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.baseline.alphabetic.html @@ -0,0 +1,48 @@ + + +Canvas test: 2d.text.draw.baseline.alphabetic + + + + + + + +

                                                                                2d.text.draw.baseline.alphabetic

                                                                                +

                                                                                + + +A +

                                                                                Actual output:

                                                                                +

                                                                                FAIL (fallback content)

                                                                                +

                                                                                Expected output:

                                                                                +

                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.basic-manual.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.basic-manual.html new file mode 100644 index 000000000..5a4be6d37 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.basic-manual.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.text.draw.fill.basic + + + + + + +

                                                                                  2d.text.draw.fill.basic

                                                                                  +

                                                                                  fillText draws filled text

                                                                                  + + +

                                                                                  Actual output:

                                                                                  +

                                                                                  FAIL (fallback content)

                                                                                  +

                                                                                  Expected output:

                                                                                  +

                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.basic.png b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.basic.png new file mode 100644 index 000000000..deaef2c95 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.basic.png differ diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.NaN.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.NaN.html new file mode 100644 index 000000000..28647ac55 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.NaN.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.text.draw.fill.maxWidth.NaN + + + + + + +

                                                                                    2d.text.draw.fill.maxWidth.NaN

                                                                                    +

                                                                                    fillText handles maxWidth correctly

                                                                                    + + +

                                                                                    Actual output:

                                                                                    +

                                                                                    FAIL (fallback content)

                                                                                    +

                                                                                    Expected output:

                                                                                    +

                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.bound.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.bound.html new file mode 100644 index 000000000..3282f273e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.bound.html @@ -0,0 +1,45 @@ + + +Canvas test: 2d.text.draw.fill.maxWidth.bound + + + + + + + +

                                                                                      2d.text.draw.fill.maxWidth.bound

                                                                                      +

                                                                                      fillText handles maxWidth based on line size, not bounding box size

                                                                                      + + +A +

                                                                                      Actual output:

                                                                                      +

                                                                                      FAIL (fallback content)

                                                                                      +

                                                                                      Expected output:

                                                                                      +

                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.fontface.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.fontface.html new file mode 100644 index 000000000..d138047f6 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.fontface.html @@ -0,0 +1,45 @@ + + +Canvas test: 2d.text.draw.fill.maxWidth.fontface + + + + + + + +

                                                                                        2d.text.draw.fill.maxWidth.fontface

                                                                                        +

                                                                                        fillText works on @font-face fonts

                                                                                        + + +A +

                                                                                        Actual output:

                                                                                        +

                                                                                        FAIL (fallback content)

                                                                                        +

                                                                                        Expected output:

                                                                                        +

                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.large-manual.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.large-manual.html new file mode 100644 index 000000000..5f599c84d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.large-manual.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.text.draw.fill.maxWidth.large + + + + + + +

                                                                                          2d.text.draw.fill.maxWidth.large

                                                                                          +

                                                                                          fillText handles maxWidth correctly

                                                                                          + + +

                                                                                          Actual output:

                                                                                          +

                                                                                          FAIL (fallback content)

                                                                                          +

                                                                                          Expected output:

                                                                                          +

                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.large.png b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.large.png new file mode 100644 index 000000000..deaef2c95 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.large.png differ diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.negative.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.negative.html new file mode 100644 index 000000000..a6ec4f290 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.negative.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.text.draw.fill.maxWidth.negative + + + + + + +

                                                                                            2d.text.draw.fill.maxWidth.negative

                                                                                            +

                                                                                            fillText handles maxWidth correctly

                                                                                            + + +

                                                                                            Actual output:

                                                                                            +

                                                                                            FAIL (fallback content)

                                                                                            +

                                                                                            Expected output:

                                                                                            +

                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.small.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.small.html new file mode 100644 index 000000000..d0364d872 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.small.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.text.draw.fill.maxWidth.small + + + + + + +

                                                                                              2d.text.draw.fill.maxWidth.small

                                                                                              +

                                                                                              fillText handles maxWidth correctly

                                                                                              + + +

                                                                                              Actual output:

                                                                                              +

                                                                                              FAIL (fallback content)

                                                                                              +

                                                                                              Expected output:

                                                                                              +

                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.zero.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.zero.html new file mode 100644 index 000000000..176e43197 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.zero.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.text.draw.fill.maxWidth.zero + + + + + + +

                                                                                                2d.text.draw.fill.maxWidth.zero

                                                                                                +

                                                                                                fillText handles maxWidth correctly

                                                                                                + + +

                                                                                                Actual output:

                                                                                                +

                                                                                                FAIL (fallback content)

                                                                                                +

                                                                                                Expected output:

                                                                                                +

                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.rtl-manual.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.rtl-manual.html new file mode 100644 index 000000000..1066b837d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.rtl-manual.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.text.draw.fill.rtl + + + + + + +

                                                                                                  2d.text.draw.fill.rtl

                                                                                                  +

                                                                                                  fillText respects Right-To-Left Override characters

                                                                                                  + + +

                                                                                                  Actual output:

                                                                                                  +

                                                                                                  FAIL (fallback content)

                                                                                                  +

                                                                                                  Expected output:

                                                                                                  +

                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.rtl.png b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.rtl.png new file mode 100644 index 000000000..deaef2c95 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.rtl.png differ diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.unaffected.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.unaffected.html new file mode 100644 index 000000000..a7ddee418 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fill.unaffected.html @@ -0,0 +1,42 @@ + + +Canvas test: 2d.text.draw.fill.unaffected + + + + + + +

                                                                                                    2d.text.draw.fill.unaffected

                                                                                                    +

                                                                                                    fillText does not start a new path or subpath

                                                                                                    + + +

                                                                                                    Actual output:

                                                                                                    +

                                                                                                    FAIL (fallback content)

                                                                                                    +

                                                                                                    Expected output:

                                                                                                    +

                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fontface.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fontface.html new file mode 100644 index 000000000..7bfbb7feb --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fontface.html @@ -0,0 +1,45 @@ + + +Canvas test: 2d.text.draw.fontface + + + + + + + +

                                                                                                      2d.text.draw.fontface

                                                                                                      +

                                                                                                      + + +A +

                                                                                                      Actual output:

                                                                                                      +

                                                                                                      FAIL (fallback content)

                                                                                                      +

                                                                                                      Expected output:

                                                                                                      +

                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fontface.notinpage.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fontface.notinpage.html new file mode 100644 index 000000000..6c4eb4919 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fontface.notinpage.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.text.draw.fontface.notinpage + + + + + + + +

                                                                                                        2d.text.draw.fontface.notinpage

                                                                                                        +

                                                                                                        @font-face fonts should work even if they are not used in the page

                                                                                                        + + +

                                                                                                        Actual output:

                                                                                                        +

                                                                                                        FAIL (fallback content)

                                                                                                        +

                                                                                                        Expected output:

                                                                                                        +

                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fontface.repeat.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fontface.repeat.html new file mode 100644 index 000000000..30cfb4c7f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.fontface.repeat.html @@ -0,0 +1,45 @@ + + +Canvas test: 2d.text.draw.fontface.repeat + + + + + + + +

                                                                                                          2d.text.draw.fontface.repeat

                                                                                                          +

                                                                                                          Draw with the font immediately, then wait a bit until and draw again. (This crashes some version of WebKit.)

                                                                                                          + + +

                                                                                                          Actual output:

                                                                                                          +

                                                                                                          FAIL (fallback content)

                                                                                                          +

                                                                                                          Expected output:

                                                                                                          +

                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.kern.consistent-manual.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.kern.consistent-manual.html new file mode 100644 index 000000000..12618f4f6 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.kern.consistent-manual.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.text.draw.kern.consistent + + + + + + +

                                                                                                            2d.text.draw.kern.consistent

                                                                                                            +

                                                                                                            Stroked and filled text should have exactly the same kerning so it overlaps

                                                                                                            + + +

                                                                                                            Actual output:

                                                                                                            +

                                                                                                            FAIL (fallback content)

                                                                                                            +

                                                                                                            Expected output:

                                                                                                            +

                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.space.basic.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.space.basic.html new file mode 100644 index 000000000..046ce7c7a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.space.basic.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.text.draw.space.basic + + + + + + + +

                                                                                                              2d.text.draw.space.basic

                                                                                                              +

                                                                                                              U+0020 is rendered the correct size (1em wide)

                                                                                                              + + +A +

                                                                                                              Actual output:

                                                                                                              +

                                                                                                              FAIL (fallback content)

                                                                                                              +

                                                                                                              Expected output:

                                                                                                              +

                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.space.collapse.nonspace.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.space.collapse.nonspace.html new file mode 100644 index 000000000..9dd441ade --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.space.collapse.nonspace.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.text.draw.space.collapse.nonspace + + + + + + + +

                                                                                                                2d.text.draw.space.collapse.nonspace

                                                                                                                +

                                                                                                                Non-space characters are not converted to U+0020 and collapsed

                                                                                                                + + +A +

                                                                                                                Actual output:

                                                                                                                +

                                                                                                                FAIL (fallback content)

                                                                                                                +

                                                                                                                Expected output:

                                                                                                                +

                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.stroke.basic-manual.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.stroke.basic-manual.html new file mode 100644 index 000000000..f9eac1f62 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.stroke.basic-manual.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.text.draw.stroke.basic + + + + + + +

                                                                                                                  2d.text.draw.stroke.basic

                                                                                                                  +

                                                                                                                  strokeText draws stroked text

                                                                                                                  + + +

                                                                                                                  Actual output:

                                                                                                                  +

                                                                                                                  FAIL (fallback content)

                                                                                                                  +

                                                                                                                  Expected output:

                                                                                                                  +

                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.stroke.basic.png b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.stroke.basic.png new file mode 100644 index 000000000..fe1b43b46 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.stroke.basic.png differ diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.stroke.unaffected.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.stroke.unaffected.html new file mode 100644 index 000000000..1da4d9277 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.draw.stroke.unaffected.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.text.draw.stroke.unaffected + + + + + + +

                                                                                                                    2d.text.draw.stroke.unaffected

                                                                                                                    +

                                                                                                                    strokeText does not start a new path or subpath

                                                                                                                    + + +

                                                                                                                    Actual output:

                                                                                                                    +

                                                                                                                    FAIL (fallback content)

                                                                                                                    +

                                                                                                                    Expected output:

                                                                                                                    +

                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.measure.width.basic.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.measure.width.basic.html new file mode 100644 index 000000000..40b43dece --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.measure.width.basic.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.text.measure.width.basic + + + + + + + +

                                                                                                                      2d.text.measure.width.basic

                                                                                                                      +

                                                                                                                      + + +A +

                                                                                                                      Actual output:

                                                                                                                      +

                                                                                                                      FAIL (fallback content)

                                                                                                                      + +
                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.measure.width.empty.html b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.measure.width.empty.html new file mode 100644 index 000000000..67a9b405a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/drawing-text-to-the-canvas/2d.text.measure.width.empty.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.text.measure.width.empty + + + + + + + +

                                                                                                                        2d.text.measure.width.empty

                                                                                                                        +

                                                                                                                        The empty string has zero width

                                                                                                                        + + +A +

                                                                                                                        Actual output:

                                                                                                                        +

                                                                                                                        FAIL (fallback content)

                                                                                                                        + +
                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/drawingstyle-objects/.gitkeep b/testing/web-platform/tests/2dcontext/drawingstyle-objects/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/testing/web-platform/tests/2dcontext/examples/.gitkeep b/testing/web-platform/tests/2dcontext/examples/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/.gitkeep b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.default.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.default.html new file mode 100644 index 000000000..a14475d7d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.default.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.fillStyle.default + + + + + + +

                                                                                                                          2d.fillStyle.default

                                                                                                                          +

                                                                                                                          + + +

                                                                                                                          Actual output:

                                                                                                                          +

                                                                                                                          FAIL (fallback content)

                                                                                                                          + +
                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.get.semitransparent.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.get.semitransparent.html new file mode 100644 index 000000000..d8a1d4178 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.get.semitransparent.html @@ -0,0 +1,28 @@ + + +Canvas test: 2d.fillStyle.get.semitransparent + + + + + + +

                                                                                                                            2d.fillStyle.get.semitransparent

                                                                                                                            +

                                                                                                                            + + +

                                                                                                                            Actual output:

                                                                                                                            +

                                                                                                                            FAIL (fallback content)

                                                                                                                            + +
                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.get.solid.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.get.solid.html new file mode 100644 index 000000000..8fc44b1c8 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.get.solid.html @@ -0,0 +1,28 @@ + + +Canvas test: 2d.fillStyle.get.solid + + + + + + +

                                                                                                                              2d.fillStyle.get.solid

                                                                                                                              +

                                                                                                                              + + +

                                                                                                                              Actual output:

                                                                                                                              +

                                                                                                                              FAIL (fallback content)

                                                                                                                              + +
                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.get.transparent.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.get.transparent.html new file mode 100644 index 000000000..3775cf3f9 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.get.transparent.html @@ -0,0 +1,28 @@ + + +Canvas test: 2d.fillStyle.get.transparent + + + + + + +

                                                                                                                                2d.fillStyle.get.transparent

                                                                                                                                +

                                                                                                                                + + +

                                                                                                                                Actual output:

                                                                                                                                +

                                                                                                                                FAIL (fallback content)

                                                                                                                                + +
                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.invalidstring.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.invalidstring.html new file mode 100644 index 000000000..eaa50dd02 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.invalidstring.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.fillStyle.invalidstring + + + + + + +

                                                                                                                                  2d.fillStyle.invalidstring

                                                                                                                                  +

                                                                                                                                  + + +

                                                                                                                                  Actual output:

                                                                                                                                  +

                                                                                                                                  FAIL (fallback content)

                                                                                                                                  +

                                                                                                                                  Expected output:

                                                                                                                                  +

                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.invalidtype.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.invalidtype.html new file mode 100644 index 000000000..fb778cbfb --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.invalidtype.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.fillStyle.invalidtype + + + + + + +

                                                                                                                                    2d.fillStyle.invalidtype

                                                                                                                                    +

                                                                                                                                    + + +

                                                                                                                                    Actual output:

                                                                                                                                    +

                                                                                                                                    FAIL (fallback content)

                                                                                                                                    +

                                                                                                                                    Expected output:

                                                                                                                                    +

                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-1.html new file mode 100644 index 000000000..3dbda598b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-hsl-1 + + + + + + +

                                                                                                                                      2d.fillStyle.parse.css-color-4-hsl-1

                                                                                                                                      +

                                                                                                                                      + +

                                                                                                                                      +

                                                                                                                                      Actual output:

                                                                                                                                      +

                                                                                                                                      FAIL (fallback content)

                                                                                                                                      +

                                                                                                                                      Expected output:

                                                                                                                                      +

                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-1.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-1.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-1.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-2.html new file mode 100644 index 000000000..25e98dc79 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-hsl-2 + + + + + + +

                                                                                                                                        2d.fillStyle.parse.css-color-4-hsl-2

                                                                                                                                        +

                                                                                                                                        + +

                                                                                                                                        +

                                                                                                                                        Actual output:

                                                                                                                                        +

                                                                                                                                        FAIL (fallback content)

                                                                                                                                        +

                                                                                                                                        Expected output:

                                                                                                                                        +

                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-2.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-2.png new file mode 100644 index 000000000..c5661de82 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-2.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-3.html new file mode 100644 index 000000000..de600d94b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-3.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-hsl-3 + + + + + + +

                                                                                                                                          2d.fillStyle.parse.css-color-4-hsl-3

                                                                                                                                          +

                                                                                                                                          + +

                                                                                                                                          +

                                                                                                                                          Actual output:

                                                                                                                                          +

                                                                                                                                          FAIL (fallback content)

                                                                                                                                          +

                                                                                                                                          Expected output:

                                                                                                                                          +

                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-3.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-3.png new file mode 100644 index 000000000..c5661de82 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-3.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-4.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-4.html new file mode 100644 index 000000000..52d917c6c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-4.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-hsl-4 + + + + + + +

                                                                                                                                            2d.fillStyle.parse.css-color-4-hsl-4

                                                                                                                                            +

                                                                                                                                            + +

                                                                                                                                            +

                                                                                                                                            Actual output:

                                                                                                                                            +

                                                                                                                                            FAIL (fallback content)

                                                                                                                                            +

                                                                                                                                            Expected output:

                                                                                                                                            +

                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-4.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-4.png new file mode 100644 index 000000000..c5661de82 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-4.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-5.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-5.html new file mode 100644 index 000000000..4f65b3dea --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-5.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-hsl-5 + + + + + + +

                                                                                                                                              2d.fillStyle.parse.css-color-4-hsl-5

                                                                                                                                              +

                                                                                                                                              + +

                                                                                                                                              +

                                                                                                                                              Actual output:

                                                                                                                                              +

                                                                                                                                              FAIL (fallback content)

                                                                                                                                              +

                                                                                                                                              Expected output:

                                                                                                                                              +

                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-5.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-5.png new file mode 100644 index 000000000..c5661de82 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-5.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-6.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-6.html new file mode 100644 index 000000000..19aa5974f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-6.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-hsl-6 + + + + + + +

                                                                                                                                                2d.fillStyle.parse.css-color-4-hsl-6

                                                                                                                                                +

                                                                                                                                                + +

                                                                                                                                                +

                                                                                                                                                Actual output:

                                                                                                                                                +

                                                                                                                                                FAIL (fallback content)

                                                                                                                                                +

                                                                                                                                                Expected output:

                                                                                                                                                +

                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-6.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-6.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-6.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-7.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-7.html new file mode 100644 index 000000000..d9b6a3c98 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-7.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-hsl-7 + + + + + + +

                                                                                                                                                  2d.fillStyle.parse.css-color-4-hsl-7

                                                                                                                                                  +

                                                                                                                                                  + +

                                                                                                                                                  +

                                                                                                                                                  Actual output:

                                                                                                                                                  +

                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                  +

                                                                                                                                                  Expected output:

                                                                                                                                                  +

                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-7.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-7.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-7.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-8.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-8.html new file mode 100644 index 000000000..24e2b5183 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-8.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-hsl-8 + + + + + + +

                                                                                                                                                    2d.fillStyle.parse.css-color-4-hsl-8

                                                                                                                                                    +

                                                                                                                                                    + +

                                                                                                                                                    +

                                                                                                                                                    Actual output:

                                                                                                                                                    +

                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                    +

                                                                                                                                                    Expected output:

                                                                                                                                                    +

                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-8.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-8.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-8.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-9.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-9.html new file mode 100644 index 000000000..9da548f3e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-9.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-hsl-9 + + + + + + +

                                                                                                                                                      2d.fillStyle.parse.css-color-4-hsl-9

                                                                                                                                                      +

                                                                                                                                                      + +

                                                                                                                                                      +

                                                                                                                                                      Actual output:

                                                                                                                                                      +

                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                      +

                                                                                                                                                      Expected output:

                                                                                                                                                      +

                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-9.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-9.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsl-9.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-1.html new file mode 100644 index 000000000..65881eeb1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-hsla-1 + + + + + + +

                                                                                                                                                        2d.fillStyle.parse.css-color-4-hsla-1

                                                                                                                                                        +

                                                                                                                                                        + +

                                                                                                                                                        +

                                                                                                                                                        Actual output:

                                                                                                                                                        +

                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                        +

                                                                                                                                                        Expected output:

                                                                                                                                                        +

                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-1.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-1.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-1.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-2.html new file mode 100644 index 000000000..91f5e3459 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-hsla-2 + + + + + + +

                                                                                                                                                          2d.fillStyle.parse.css-color-4-hsla-2

                                                                                                                                                          +

                                                                                                                                                          + +

                                                                                                                                                          +

                                                                                                                                                          Actual output:

                                                                                                                                                          +

                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                          +

                                                                                                                                                          Expected output:

                                                                                                                                                          +

                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-2.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-2.png new file mode 100644 index 000000000..c5661de82 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-2.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-3.html new file mode 100644 index 000000000..eb6c69526 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-3.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-hsla-3 + + + + + + +

                                                                                                                                                            2d.fillStyle.parse.css-color-4-hsla-3

                                                                                                                                                            +

                                                                                                                                                            + +

                                                                                                                                                            +

                                                                                                                                                            Actual output:

                                                                                                                                                            +

                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                            +

                                                                                                                                                            Expected output:

                                                                                                                                                            +

                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-3.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-3.png new file mode 100644 index 000000000..c5661de82 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-3.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-4.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-4.html new file mode 100644 index 000000000..ce5bdef7a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-4.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-hsla-4 + + + + + + +

                                                                                                                                                              2d.fillStyle.parse.css-color-4-hsla-4

                                                                                                                                                              +

                                                                                                                                                              + +

                                                                                                                                                              +

                                                                                                                                                              Actual output:

                                                                                                                                                              +

                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                              +

                                                                                                                                                              Expected output:

                                                                                                                                                              +

                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-4.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-4.png new file mode 100644 index 000000000..c5661de82 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-4.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-5.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-5.html new file mode 100644 index 000000000..47b426daf --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-5.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-hsla-5 + + + + + + +

                                                                                                                                                                2d.fillStyle.parse.css-color-4-hsla-5

                                                                                                                                                                +

                                                                                                                                                                + +

                                                                                                                                                                +

                                                                                                                                                                Actual output:

                                                                                                                                                                +

                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                +

                                                                                                                                                                Expected output:

                                                                                                                                                                +

                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-5.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-5.png new file mode 100644 index 000000000..c5661de82 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-5.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-6.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-6.html new file mode 100644 index 000000000..6dc5e7aef --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-6.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-hsla-6 + + + + + + +

                                                                                                                                                                  2d.fillStyle.parse.css-color-4-hsla-6

                                                                                                                                                                  +

                                                                                                                                                                  + +

                                                                                                                                                                  +

                                                                                                                                                                  Actual output:

                                                                                                                                                                  +

                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                  +

                                                                                                                                                                  Expected output:

                                                                                                                                                                  +

                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-6.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-6.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-6.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-7.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-7.html new file mode 100644 index 000000000..a1069fea9 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-7.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-hsla-7 + + + + + + +

                                                                                                                                                                    2d.fillStyle.parse.css-color-4-hsla-7

                                                                                                                                                                    +

                                                                                                                                                                    + +

                                                                                                                                                                    +

                                                                                                                                                                    Actual output:

                                                                                                                                                                    +

                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                    +

                                                                                                                                                                    Expected output:

                                                                                                                                                                    +

                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-7.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-7.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-7.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-8.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-8.html new file mode 100644 index 000000000..7d04b1ca5 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-8.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-hsla-8 + + + + + + +

                                                                                                                                                                      2d.fillStyle.parse.css-color-4-hsla-8

                                                                                                                                                                      +

                                                                                                                                                                      + +

                                                                                                                                                                      +

                                                                                                                                                                      Actual output:

                                                                                                                                                                      +

                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                      +

                                                                                                                                                                      Expected output:

                                                                                                                                                                      +

                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-8.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-8.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-8.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-9.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-9.html new file mode 100644 index 000000000..0a10c6e61 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-9.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-hsla-9 + + + + + + +

                                                                                                                                                                        2d.fillStyle.parse.css-color-4-hsla-9

                                                                                                                                                                        +

                                                                                                                                                                        + +

                                                                                                                                                                        +

                                                                                                                                                                        Actual output:

                                                                                                                                                                        +

                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                        +

                                                                                                                                                                        Expected output:

                                                                                                                                                                        +

                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-9.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-9.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-hsla-9.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-1.html new file mode 100644 index 000000000..fd6376e1a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-rgb-1 + + + + + + +

                                                                                                                                                                          2d.fillStyle.parse.css-color-4-rgb-1

                                                                                                                                                                          +

                                                                                                                                                                          + +

                                                                                                                                                                          +

                                                                                                                                                                          Actual output:

                                                                                                                                                                          +

                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                          +

                                                                                                                                                                          Expected output:

                                                                                                                                                                          +

                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-1.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-1.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-1.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-2.html new file mode 100644 index 000000000..ec0f62344 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-rgb-2 + + + + + + +

                                                                                                                                                                            2d.fillStyle.parse.css-color-4-rgb-2

                                                                                                                                                                            +

                                                                                                                                                                            + +

                                                                                                                                                                            +

                                                                                                                                                                            Actual output:

                                                                                                                                                                            +

                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                            +

                                                                                                                                                                            Expected output:

                                                                                                                                                                            +

                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-2.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-2.png new file mode 100644 index 000000000..c5661de82 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-2.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-3.html new file mode 100644 index 000000000..980abef36 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-3.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-rgb-3 + + + + + + +

                                                                                                                                                                              2d.fillStyle.parse.css-color-4-rgb-3

                                                                                                                                                                              +

                                                                                                                                                                              + +

                                                                                                                                                                              +

                                                                                                                                                                              Actual output:

                                                                                                                                                                              +

                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                              +

                                                                                                                                                                              Expected output:

                                                                                                                                                                              +

                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-3.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-3.png new file mode 100644 index 000000000..c5661de82 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-3.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-4.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-4.html new file mode 100644 index 000000000..a2543b566 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-4.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-rgb-4 + + + + + + +

                                                                                                                                                                                2d.fillStyle.parse.css-color-4-rgb-4

                                                                                                                                                                                +

                                                                                                                                                                                + +

                                                                                                                                                                                +

                                                                                                                                                                                Actual output:

                                                                                                                                                                                +

                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                +

                                                                                                                                                                                Expected output:

                                                                                                                                                                                +

                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-4.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-4.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-4.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-5.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-5.html new file mode 100644 index 000000000..6b310d763 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-5.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-rgb-5 + + + + + + +

                                                                                                                                                                                  2d.fillStyle.parse.css-color-4-rgb-5

                                                                                                                                                                                  +

                                                                                                                                                                                  + +

                                                                                                                                                                                  +

                                                                                                                                                                                  Actual output:

                                                                                                                                                                                  +

                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                  +

                                                                                                                                                                                  Expected output:

                                                                                                                                                                                  +

                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-5.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-5.png new file mode 100644 index 000000000..c5661de82 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-5.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-6.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-6.html new file mode 100644 index 000000000..d38f7e0ac --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-6.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-rgb-6 + + + + + + +

                                                                                                                                                                                    2d.fillStyle.parse.css-color-4-rgb-6

                                                                                                                                                                                    +

                                                                                                                                                                                    + +

                                                                                                                                                                                    +

                                                                                                                                                                                    Actual output:

                                                                                                                                                                                    +

                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                    +

                                                                                                                                                                                    Expected output:

                                                                                                                                                                                    +

                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-6.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-6.png new file mode 100644 index 000000000..c5661de82 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgb-6.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-1.html new file mode 100644 index 000000000..83dfb2f86 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-rgba-1 + + + + + + +

                                                                                                                                                                                      2d.fillStyle.parse.css-color-4-rgba-1

                                                                                                                                                                                      +

                                                                                                                                                                                      + +

                                                                                                                                                                                      +

                                                                                                                                                                                      Actual output:

                                                                                                                                                                                      +

                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                      +

                                                                                                                                                                                      Expected output:

                                                                                                                                                                                      +

                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-1.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-1.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-1.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-2.html new file mode 100644 index 000000000..390d0bd0f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-rgba-2 + + + + + + +

                                                                                                                                                                                        2d.fillStyle.parse.css-color-4-rgba-2

                                                                                                                                                                                        +

                                                                                                                                                                                        + +

                                                                                                                                                                                        +

                                                                                                                                                                                        Actual output:

                                                                                                                                                                                        +

                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                        +

                                                                                                                                                                                        Expected output:

                                                                                                                                                                                        +

                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-2.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-2.png new file mode 100644 index 000000000..c5661de82 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-2.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-3.html new file mode 100644 index 000000000..f0fd88ee6 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-3.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-rgba-3 + + + + + + +

                                                                                                                                                                                          2d.fillStyle.parse.css-color-4-rgba-3

                                                                                                                                                                                          +

                                                                                                                                                                                          + +

                                                                                                                                                                                          +

                                                                                                                                                                                          Actual output:

                                                                                                                                                                                          +

                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                          +

                                                                                                                                                                                          Expected output:

                                                                                                                                                                                          +

                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-3.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-3.png new file mode 100644 index 000000000..c5661de82 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-3.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-4.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-4.html new file mode 100644 index 000000000..bd3e8edb2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-4.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-rgba-4 + + + + + + +

                                                                                                                                                                                            2d.fillStyle.parse.css-color-4-rgba-4

                                                                                                                                                                                            +

                                                                                                                                                                                            + +

                                                                                                                                                                                            +

                                                                                                                                                                                            Actual output:

                                                                                                                                                                                            +

                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                            +

                                                                                                                                                                                            Expected output:

                                                                                                                                                                                            +

                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-4.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-4.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-4.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-5.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-5.html new file mode 100644 index 000000000..0287ef693 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-5.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-rgba-5 + + + + + + +

                                                                                                                                                                                              2d.fillStyle.parse.css-color-4-rgba-5

                                                                                                                                                                                              +

                                                                                                                                                                                              + +

                                                                                                                                                                                              +

                                                                                                                                                                                              Actual output:

                                                                                                                                                                                              +

                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                              +

                                                                                                                                                                                              Expected output:

                                                                                                                                                                                              +

                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-5.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-5.png new file mode 100644 index 000000000..c5661de82 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-5.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-6.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-6.html new file mode 100644 index 000000000..09042c877 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-6.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.css-color-4-rgba-6 + + + + + + +

                                                                                                                                                                                                2d.fillStyle.parse.css-color-4-rgba-6

                                                                                                                                                                                                +

                                                                                                                                                                                                + +

                                                                                                                                                                                                +

                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                +

                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                +

                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                +

                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-6.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-6.png new file mode 100644 index 000000000..c5661de82 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.css-color-4-rgba-6.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.current.basic.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.current.basic.html new file mode 100644 index 000000000..271adfd8b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.current.basic.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.current.basic + + + + + + +

                                                                                                                                                                                                  2d.fillStyle.parse.current.basic

                                                                                                                                                                                                  +

                                                                                                                                                                                                  currentColor is computed from the canvas element

                                                                                                                                                                                                  + + +

                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                  +

                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                  +

                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                  +

                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.current.changed.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.current.changed.html new file mode 100644 index 000000000..591b6d256 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.current.changed.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.fillStyle.parse.current.changed + + + + + + +

                                                                                                                                                                                                    2d.fillStyle.parse.current.changed

                                                                                                                                                                                                    +

                                                                                                                                                                                                    currentColor is computed when the attribute is set, not when it is painted

                                                                                                                                                                                                    + + +

                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                    +

                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                    +

                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                    +

                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.current.notrendered.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.current.notrendered.html new file mode 100644 index 000000000..3e8f007f9 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.current.notrendered.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.fillStyle.parse.current.notrendered + + + + + + +

                                                                                                                                                                                                      2d.fillStyle.parse.current.basic

                                                                                                                                                                                                      +

                                                                                                                                                                                                      currentColor is computed from the canvas element

                                                                                                                                                                                                      + + +

                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                      +

                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                      +

                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                      +

                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.current.removed.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.current.removed.html new file mode 100644 index 000000000..a46e9c975 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.current.removed.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.fillStyle.parse.current.removed + + + + + + +

                                                                                                                                                                                                        2d.fillStyle.parse.current.removed

                                                                                                                                                                                                        +

                                                                                                                                                                                                        currentColor is solid black when the canvas element is not in a document

                                                                                                                                                                                                        + + +

                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                        +

                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                        +

                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                        +

                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.current.removed.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.current.removed.png new file mode 100644 index 000000000..d638d0338 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.current.removed.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex3.html new file mode 100644 index 000000000..635a59a72 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex3.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.hex3 + + + + + + +

                                                                                                                                                                                                          2d.fillStyle.parse.hex3

                                                                                                                                                                                                          +

                                                                                                                                                                                                          + +

                                                                                                                                                                                                          +

                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                          +

                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                          +

                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                          +

                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex3.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex3.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex3.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex4.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex4.html new file mode 100644 index 000000000..8462248e8 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex4.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.hex4 + + + + + + +

                                                                                                                                                                                                            2d.fillStyle.parse.hex4

                                                                                                                                                                                                            +

                                                                                                                                                                                                            + +

                                                                                                                                                                                                            +

                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                            +

                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                            +

                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                            +

                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex4.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex4.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex4.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex6.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex6.html new file mode 100644 index 000000000..37a420800 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex6.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.hex6 + + + + + + +

                                                                                                                                                                                                              2d.fillStyle.parse.hex6

                                                                                                                                                                                                              +

                                                                                                                                                                                                              + +

                                                                                                                                                                                                              +

                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                              +

                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                              +

                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                              +

                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex6.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex6.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex6.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex8.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex8.html new file mode 100644 index 000000000..36ade5748 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex8.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.hex8 + + + + + + +

                                                                                                                                                                                                                2d.fillStyle.parse.hex8

                                                                                                                                                                                                                +

                                                                                                                                                                                                                + +

                                                                                                                                                                                                                +

                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                +

                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                +

                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                +

                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex8.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex8.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hex8.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-1.html new file mode 100644 index 000000000..53b1f5d40 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.hsl-1 + + + + + + +

                                                                                                                                                                                                                  2d.fillStyle.parse.hsl-1

                                                                                                                                                                                                                  +

                                                                                                                                                                                                                  + +

                                                                                                                                                                                                                  +

                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                  +

                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                  +

                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                  +

                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-1.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-1.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-1.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-2.html new file mode 100644 index 000000000..39790e979 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.hsl-2 + + + + + + +

                                                                                                                                                                                                                    2d.fillStyle.parse.hsl-2

                                                                                                                                                                                                                    +

                                                                                                                                                                                                                    + +

                                                                                                                                                                                                                    +

                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                    +

                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                    +

                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                    +

                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-2.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-2.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-2.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-3.html new file mode 100644 index 000000000..2befaab2e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-3.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.hsl-3 + + + + + + +

                                                                                                                                                                                                                      2d.fillStyle.parse.hsl-3

                                                                                                                                                                                                                      +

                                                                                                                                                                                                                      + +

                                                                                                                                                                                                                      +

                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                      +

                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                      +

                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                      +

                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-3.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-3.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-3.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-4.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-4.html new file mode 100644 index 000000000..9f8e7cac1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-4.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.hsl-4 + + + + + + +

                                                                                                                                                                                                                        2d.fillStyle.parse.hsl-4

                                                                                                                                                                                                                        +

                                                                                                                                                                                                                        + +

                                                                                                                                                                                                                        +

                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                        +

                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                        +

                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                        +

                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-4.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-4.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-4.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-5.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-5.html new file mode 100644 index 000000000..881bc0492 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-5.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.hsl-5 + + + + + + +

                                                                                                                                                                                                                          2d.fillStyle.parse.hsl-5

                                                                                                                                                                                                                          +

                                                                                                                                                                                                                          + +

                                                                                                                                                                                                                          +

                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                          +

                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                          +

                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                          +

                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-5.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-5.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-5.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-6.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-6.html new file mode 100644 index 000000000..f2636336c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-6.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.hsl-6 + + + + + + +

                                                                                                                                                                                                                            2d.fillStyle.parse.hsl-6

                                                                                                                                                                                                                            +

                                                                                                                                                                                                                            + +

                                                                                                                                                                                                                            +

                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                            +

                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                            +

                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                            +

                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-6.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-6.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-6.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-1.html new file mode 100644 index 000000000..a2fce10dc --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.hsl-clamp-1 + + + + + + +

                                                                                                                                                                                                                              2d.fillStyle.parse.hsl-clamp-1

                                                                                                                                                                                                                              +

                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                              +

                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                              +

                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                              +

                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-1.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-1.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-1.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-2.html new file mode 100644 index 000000000..0a245a4df --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.hsl-clamp-2 + + + + + + +

                                                                                                                                                                                                                                2d.fillStyle.parse.hsl-clamp-2

                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                + +

                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-2.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-2.png new file mode 100644 index 000000000..88fd82798 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-2.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-3.html new file mode 100644 index 000000000..ed14332f8 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-3.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.hsl-clamp-3 + + + + + + +

                                                                                                                                                                                                                                  2d.fillStyle.parse.hsl-clamp-3

                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                  + +

                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-3.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-3.png new file mode 100644 index 000000000..bf48767a8 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-3.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-4.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-4.html new file mode 100644 index 000000000..a27379c5e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-4.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.hsl-clamp-4 + + + + + + +

                                                                                                                                                                                                                                    2d.fillStyle.parse.hsl-clamp-4

                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                    + +

                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-4.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-4.png new file mode 100644 index 000000000..d638d0338 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsl-clamp-4.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-1.html new file mode 100644 index 000000000..2e835a8b3 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.hsla-1 + + + + + + +

                                                                                                                                                                                                                                      2d.fillStyle.parse.hsla-1

                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                      + +

                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-1.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-1.png new file mode 100644 index 000000000..2aa6265f0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-1.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-2.html new file mode 100644 index 000000000..a7db6ac10 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.hsla-2 + + + + + + +

                                                                                                                                                                                                                                        2d.fillStyle.parse.hsla-2

                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                        + +

                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-2.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-2.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-2.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-1.html new file mode 100644 index 000000000..13652aab1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.hsla-clamp-1 + + + + + + +

                                                                                                                                                                                                                                          2d.fillStyle.parse.hsla-clamp-1

                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                          + +

                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-1.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-1.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-1.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-2.html new file mode 100644 index 000000000..98f2505a5 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.hsla-clamp-2 + + + + + + +

                                                                                                                                                                                                                                            2d.fillStyle.parse.hsla-clamp-2

                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                            + +

                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-2.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-2.png new file mode 100644 index 000000000..88fd82798 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-2.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-3.html new file mode 100644 index 000000000..0aa08807a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-3.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.hsla-clamp-3 + + + + + + +

                                                                                                                                                                                                                                              2d.fillStyle.parse.hsla-clamp-3

                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-3.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-3.png new file mode 100644 index 000000000..bf48767a8 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-3.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-4.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-4.html new file mode 100644 index 000000000..ab5da396c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-4.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.hsla-clamp-4 + + + + + + +

                                                                                                                                                                                                                                                2d.fillStyle.parse.hsla-clamp-4

                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                + +

                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-4.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-4.png new file mode 100644 index 000000000..d638d0338 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-4.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-5.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-5.html new file mode 100644 index 000000000..a64f89303 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-5.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.hsla-clamp-5 + + + + + + +

                                                                                                                                                                                                                                                  2d.fillStyle.parse.hsla-clamp-5

                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                  + +

                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-5.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-5.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-5.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-6.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-6.html new file mode 100644 index 000000000..60b464a62 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-6.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.hsla-clamp-6 + + + + + + +

                                                                                                                                                                                                                                                    2d.fillStyle.parse.hsla-clamp-6

                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                    + +

                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-6.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-6.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-6.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.html4.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.html4.html new file mode 100644 index 000000000..3dd7d37eb --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.html4.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.html4 + + + + + + +

                                                                                                                                                                                                                                                      2d.fillStyle.parse.html4

                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                      + +

                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.html4.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.html4.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.html4.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsl-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsl-1.html new file mode 100644 index 000000000..25bab97b0 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsl-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.css-color-4-hsl-1 + + + + + + +

                                                                                                                                                                                                                                                        2d.fillStyle.parse.invalid.css-color-4-hsl-1

                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsl-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsl-2.html new file mode 100644 index 000000000..f4a47f5d8 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsl-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.css-color-4-hsl-2 + + + + + + +

                                                                                                                                                                                                                                                          2d.fillStyle.parse.invalid.css-color-4-hsl-2

                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsl-3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsl-3.html new file mode 100644 index 000000000..490c66f36 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsl-3.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.css-color-4-hsl-3 + + + + + + +

                                                                                                                                                                                                                                                            2d.fillStyle.parse.invalid.css-color-4-hsl-3

                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsl-4.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsl-4.html new file mode 100644 index 000000000..a3ab91c16 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsl-4.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.css-color-4-hsl-4 + + + + + + +

                                                                                                                                                                                                                                                              2d.fillStyle.parse.invalid.css-color-4-hsl-4

                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsl-5.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsl-5.html new file mode 100644 index 000000000..a437cd99c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsl-5.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.css-color-4-hsl-5 + + + + + + +

                                                                                                                                                                                                                                                                2d.fillStyle.parse.invalid.css-color-4-hsl-5

                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsla-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsla-1.html new file mode 100644 index 000000000..5f71de330 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsla-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.css-color-4-hsla-1 + + + + + + +

                                                                                                                                                                                                                                                                  2d.fillStyle.parse.invalid.css-color-4-hsla-1

                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsla-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsla-2.html new file mode 100644 index 000000000..36c9fd1a6 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsla-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.css-color-4-hsla-2 + + + + + + +

                                                                                                                                                                                                                                                                    2d.fillStyle.parse.invalid.css-color-4-hsla-2

                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsla-3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsla-3.html new file mode 100644 index 000000000..049ad397e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-hsla-3.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.css-color-4-hsla-3 + + + + + + +

                                                                                                                                                                                                                                                                      2d.fillStyle.parse.invalid.css-color-4-hsla-3

                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgb-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgb-1.html new file mode 100644 index 000000000..7a2534ceb --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgb-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.css-color-4-rgb-1 + + + + + + +

                                                                                                                                                                                                                                                                        2d.fillStyle.parse.invalid.css-color-4-rgb-1

                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgb-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgb-2.html new file mode 100644 index 000000000..ca5a591ef --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgb-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.css-color-4-rgb-2 + + + + + + +

                                                                                                                                                                                                                                                                          2d.fillStyle.parse.invalid.css-color-4-rgb-2

                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgb-3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgb-3.html new file mode 100644 index 000000000..e34ddfdf9 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgb-3.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.css-color-4-rgb-3 + + + + + + +

                                                                                                                                                                                                                                                                            2d.fillStyle.parse.invalid.css-color-4-rgb-3

                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgb-4.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgb-4.html new file mode 100644 index 000000000..682da31d2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgb-4.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.css-color-4-rgb-4 + + + + + + +

                                                                                                                                                                                                                                                                              2d.fillStyle.parse.invalid.css-color-4-rgb-4

                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgb-5.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgb-5.html new file mode 100644 index 000000000..75a11dc19 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgb-5.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.css-color-4-rgb-5 + + + + + + +

                                                                                                                                                                                                                                                                                2d.fillStyle.parse.invalid.css-color-4-rgb-5

                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgba-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgba-1.html new file mode 100644 index 000000000..778fa479c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgba-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.css-color-4-rgba-1 + + + + + + +

                                                                                                                                                                                                                                                                                  2d.fillStyle.parse.invalid.css-color-4-rgba-1

                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgba-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgba-2.html new file mode 100644 index 000000000..14c83a569 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgba-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.css-color-4-rgba-2 + + + + + + +

                                                                                                                                                                                                                                                                                    2d.fillStyle.parse.invalid.css-color-4-rgba-2

                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgba-3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgba-3.html new file mode 100644 index 000000000..9647877b2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.css-color-4-rgba-3.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.css-color-4-rgba-3 + + + + + + +

                                                                                                                                                                                                                                                                                      2d.fillStyle.parse.invalid.css-color-4-rgba-3

                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex1.html new file mode 100644 index 000000000..36a9489e1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.hex1 + + + + + + +

                                                                                                                                                                                                                                                                                        2d.fillStyle.parse.invalid.hex1

                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex2.html new file mode 100644 index 000000000..5a1758fc5 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.hex2 + + + + + + +

                                                                                                                                                                                                                                                                                          2d.fillStyle.parse.invalid.hex2

                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex3.html new file mode 100644 index 000000000..f1ada9f19 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex3.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.hex3 + + + + + + +

                                                                                                                                                                                                                                                                                            2d.fillStyle.parse.invalid.hex3

                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex4.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex4.html new file mode 100644 index 000000000..36e312d63 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex4.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.hex4 + + + + + + +

                                                                                                                                                                                                                                                                                              2d.fillStyle.parse.invalid.hex4

                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex5.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex5.html new file mode 100644 index 000000000..19abea32a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex5.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.hex5 + + + + + + +

                                                                                                                                                                                                                                                                                                2d.fillStyle.parse.invalid.hex5

                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex6.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex6.html new file mode 100644 index 000000000..c600b9831 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex6.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.hex6 + + + + + + +

                                                                                                                                                                                                                                                                                                  2d.fillStyle.parse.invalid.hex6

                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex7.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex7.html new file mode 100644 index 000000000..cee88055e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex7.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.hex7 + + + + + + +

                                                                                                                                                                                                                                                                                                    2d.fillStyle.parse.invalid.hex7

                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex8.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex8.html new file mode 100644 index 000000000..e835d2da0 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hex8.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.hex8 + + + + + + +

                                                                                                                                                                                                                                                                                                      2d.fillStyle.parse.invalid.hex8

                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-1.html new file mode 100644 index 000000000..3acee1f39 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.hsl-1 + + + + + + +

                                                                                                                                                                                                                                                                                                        2d.fillStyle.parse.invalid.hsl-1

                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-2.html new file mode 100644 index 000000000..c2c34f524 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.hsl-2 + + + + + + +

                                                                                                                                                                                                                                                                                                          2d.fillStyle.parse.invalid.hsl-2

                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-3.html new file mode 100644 index 000000000..616639a1e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-3.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.hsl-3 + + + + + + +

                                                                                                                                                                                                                                                                                                            2d.fillStyle.parse.invalid.hsl-3

                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-4.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-4.html new file mode 100644 index 000000000..aaa2a8dc0 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-4.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.hsl-4 + + + + + + +

                                                                                                                                                                                                                                                                                                              2d.fillStyle.parse.invalid.hsl-4

                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-5.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-5.html new file mode 100644 index 000000000..0e3f85148 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-5.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.hsl-5 + + + + + + +

                                                                                                                                                                                                                                                                                                                2d.fillStyle.parse.invalid.hsl-5

                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-6.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-6.html new file mode 100644 index 000000000..6343ab125 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-6.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.hsl-6 + + + + + + +

                                                                                                                                                                                                                                                                                                                  2d.fillStyle.parse.invalid.hsl-6

                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsla-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsla-1.html new file mode 100644 index 000000000..dbddb0f55 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsla-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.hsla-1 + + + + + + +

                                                                                                                                                                                                                                                                                                                    2d.fillStyle.parse.invalid.hsla-1

                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsla-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsla-2.html new file mode 100644 index 000000000..8a9643f88 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsla-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.hsla-2 + + + + + + +

                                                                                                                                                                                                                                                                                                                      2d.fillStyle.parse.invalid.hsla-2

                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsla-3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsla-3.html new file mode 100644 index 000000000..698a6cb9a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsla-3.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.hsla-3 + + + + + + +

                                                                                                                                                                                                                                                                                                                        2d.fillStyle.parse.invalid.hsla-3

                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.name-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.name-1.html new file mode 100644 index 000000000..45dcfca0c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.name-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.name-1 + + + + + + +

                                                                                                                                                                                                                                                                                                                          2d.fillStyle.parse.invalid.name-1

                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.name-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.name-2.html new file mode 100644 index 000000000..a3016b2a1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.name-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.name-2 + + + + + + +

                                                                                                                                                                                                                                                                                                                            2d.fillStyle.parse.invalid.name-2

                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.name-3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.name-3.html new file mode 100644 index 000000000..1d56151b6 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.name-3.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.name-3 + + + + + + +

                                                                                                                                                                                                                                                                                                                              2d.fillStyle.parse.invalid.name-3

                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.name-4.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.name-4.html new file mode 100644 index 000000000..e2619ffa8 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.name-4.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.name-4 + + + + + + +

                                                                                                                                                                                                                                                                                                                                2d.fillStyle.parse.invalid.name-4

                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.name-5.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.name-5.html new file mode 100644 index 000000000..f515ff32e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.name-5.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.name-5 + + + + + + +

                                                                                                                                                                                                                                                                                                                                  2d.fillStyle.parse.invalid.name-5

                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgb-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgb-1.html new file mode 100644 index 000000000..66fb8e13d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgb-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.rgb-1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                    2d.fillStyle.parse.invalid.rgb-1

                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgb-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgb-2.html new file mode 100644 index 000000000..7f9457c82 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgb-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.rgb-2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                      2d.fillStyle.parse.invalid.rgb-2

                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgb-3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgb-3.html new file mode 100644 index 000000000..2530569c2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgb-3.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.rgb-3 + + + + + + +

                                                                                                                                                                                                                                                                                                                                        2d.fillStyle.parse.invalid.rgb-3

                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgba-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgba-1.html new file mode 100644 index 000000000..1dc343ad1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgba-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.rgba-1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                          2d.fillStyle.parse.invalid.rgba-1

                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgba-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgba-2.html new file mode 100644 index 000000000..5f5bb7941 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgba-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.rgba-2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                            2d.fillStyle.parse.invalid.rgba-2

                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgba-3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgba-3.html new file mode 100644 index 000000000..67ed7f2a2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgba-3.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.rgba-3 + + + + + + +

                                                                                                                                                                                                                                                                                                                                              2d.fillStyle.parse.invalid.rgba-3

                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgba-4.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgba-4.html new file mode 100644 index 000000000..aea9725a2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgba-4.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.rgba-4 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                2d.fillStyle.parse.invalid.rgba-4

                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgba-5.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgba-5.html new file mode 100644 index 000000000..a149ed343 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.invalid.rgba-5.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.invalid.rgba-5 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                  2d.fillStyle.parse.invalid.rgba-5

                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-1.html new file mode 100644 index 000000000..807a4961b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.rgb-clamp-1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                    2d.fillStyle.parse.rgb-clamp-1

                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                    + +

                                                                                                                                                                                                                                                                                                                                                    Assumes colours are clamped to [0,255]. +

                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-1.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-1.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-1.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-2.html new file mode 100644 index 000000000..46b3b6daa --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.rgb-clamp-2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                      2d.fillStyle.parse.rgb-clamp-2

                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                      + +

                                                                                                                                                                                                                                                                                                                                                      Assumes colours are clamped to [0,255]. +

                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-2.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-2.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-2.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-3.html new file mode 100644 index 000000000..75dbe19c6 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-3.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.rgb-clamp-3 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                        2d.fillStyle.parse.rgb-clamp-3

                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                        + +

                                                                                                                                                                                                                                                                                                                                                        Assumes colours are clamped to [0,255]. +

                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-3.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-3.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-3.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-4.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-4.html new file mode 100644 index 000000000..4888816b6 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-4.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.rgb-clamp-4 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                          2d.fillStyle.parse.rgb-clamp-4

                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                          + +

                                                                                                                                                                                                                                                                                                                                                          Assumes colours are clamped to [0,255]. +

                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-4.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-4.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-4.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-5.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-5.html new file mode 100644 index 000000000..3f7a94433 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-5.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.rgb-clamp-5 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                            2d.fillStyle.parse.rgb-clamp-5

                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                            + +

                                                                                                                                                                                                                                                                                                                                                            Assumes colours are clamped to [0,255]. +

                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-5.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-5.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-clamp-5.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-eof.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-eof.html new file mode 100644 index 000000000..0d2833ceb --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-eof.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.rgb-eof + + + + + + +

                                                                                                                                                                                                                                                                                                                                                              2d.fillStyle.parse.rgb-eof

                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-eof.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-eof.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-eof.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-num.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-num.html new file mode 100644 index 000000000..85fc99280 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-num.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.rgb-num + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                2d.fillStyle.parse.rgb-num

                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                + +

                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-num.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-num.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-num.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-percent.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-percent.html new file mode 100644 index 000000000..295e72b0d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-percent.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.rgb-percent + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                  2d.fillStyle.parse.rgb-percent

                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                  + +

                                                                                                                                                                                                                                                                                                                                                                  CSS3 Color says "The integer value 255 corresponds to 100%". (In particular, it is not 254...) +

                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-percent.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-percent.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgb-percent.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-clamp-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-clamp-1.html new file mode 100644 index 000000000..0ec2ea0a1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-clamp-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.rgba-clamp-1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                    2d.fillStyle.parse.rgba-clamp-1

                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                    + +

                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-clamp-1.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-clamp-1.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-clamp-1.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-clamp-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-clamp-2.html new file mode 100644 index 000000000..fe3520157 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-clamp-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.rgba-clamp-2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                      2d.fillStyle.parse.rgba-clamp-2

                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                      + +

                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-clamp-2.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-clamp-2.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-clamp-2.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-eof.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-eof.html new file mode 100644 index 000000000..d8856813d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-eof.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.rgba-eof + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                        2d.fillStyle.parse.rgba-eof

                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                        + +

                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-eof.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-eof.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-eof.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-num-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-num-1.html new file mode 100644 index 000000000..98dd9bf87 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-num-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.rgba-num-1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                          2d.fillStyle.parse.rgba-num-1

                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                          + +

                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-num-1.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-num-1.png new file mode 100644 index 000000000..2aa6265f0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-num-1.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-num-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-num-2.html new file mode 100644 index 000000000..5cadec16c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-num-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.rgba-num-2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                            2d.fillStyle.parse.rgba-num-2

                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                            + +

                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-num-2.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-num-2.png new file mode 100644 index 000000000..2aa6265f0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-num-2.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-percent.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-percent.html new file mode 100644 index 000000000..63f8c9ea9 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-percent.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.rgba-percent + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                              2d.fillStyle.parse.rgba-percent

                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-percent.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-percent.png new file mode 100644 index 000000000..2aa6265f0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-percent.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-1.html new file mode 100644 index 000000000..0d08a4921 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.rgba-solid-1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                2d.fillStyle.parse.rgba-solid-1

                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                + +

                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-1.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-1.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-1.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-2.html new file mode 100644 index 000000000..2a9db38ed --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.rgba-solid-2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                  2d.fillStyle.parse.rgba-solid-2

                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                  + +

                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-2.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-2.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-2.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-3.html new file mode 100644 index 000000000..81bf257cd --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-3.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.rgba-solid-3 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                    2d.fillStyle.parse.rgba-solid-3

                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                    + +

                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-3.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-3.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-3.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-4.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-4.html new file mode 100644 index 000000000..82d450c01 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-4.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.rgba-solid-4 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                      2d.fillStyle.parse.rgba-solid-4

                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                      + +

                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-4.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-4.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.rgba-solid-4.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.svg-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.svg-1.html new file mode 100644 index 000000000..c49620f03 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.svg-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.svg-1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                        2d.fillStyle.parse.svg-1

                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                        + +

                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.svg-1.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.svg-1.png new file mode 100644 index 000000000..5bc39cc69 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.svg-1.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.svg-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.svg-2.html new file mode 100644 index 000000000..3a7e3d97e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.svg-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.svg-2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                          2d.fillStyle.parse.svg-2

                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                          + +

                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.svg-2.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.svg-2.png new file mode 100644 index 000000000..5bc39cc69 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.svg-2.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.system.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.system.html new file mode 100644 index 000000000..9bb43c623 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.system.html @@ -0,0 +1,30 @@ + + +Canvas test: 2d.fillStyle.parse.system + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                            2d.fillStyle.parse.system

                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                            + +
                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.transparent-1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.transparent-1.html new file mode 100644 index 000000000..36cc80437 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.transparent-1.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.transparent-1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                              2d.fillStyle.parse.transparent-1

                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.transparent-1.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.transparent-1.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.transparent-1.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.transparent-2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.transparent-2.html new file mode 100644 index 000000000..66e282598 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.transparent-2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.fillStyle.parse.transparent-2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                2d.fillStyle.parse.transparent-2

                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                + +

                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.transparent-2.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.transparent-2.png new file mode 100644 index 000000000..eeedd0ff0 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.fillStyle.parse.transparent-2.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.empty.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.empty.html new file mode 100644 index 000000000..e087f53c3 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.empty.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.gradient.empty + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                  2d.gradient.empty

                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.alpha.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.alpha.html new file mode 100644 index 000000000..7bf486da4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.alpha.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.gradient.interpolate.alpha + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                    2d.gradient.interpolate.alpha

                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.alpha.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.alpha.png new file mode 100644 index 000000000..67f344359 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.alpha.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.colour.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.colour.html new file mode 100644 index 000000000..a5fd632b5 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.colour.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.gradient.interpolate.colour + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                      2d.gradient.interpolate.colour

                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.colour.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.colour.png new file mode 100644 index 000000000..67f344359 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.colour.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.colouralpha.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.colouralpha.html new file mode 100644 index 000000000..ad18881da --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.colouralpha.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.gradient.interpolate.colouralpha + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                        2d.gradient.interpolate.colouralpha

                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.colouralpha.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.colouralpha.png new file mode 100644 index 000000000..af6e50b7d Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.colouralpha.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.multiple.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.multiple.html new file mode 100644 index 000000000..b6b8de135 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.multiple.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.gradient.interpolate.multiple + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                          2d.gradient.interpolate.multiple

                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.multiple.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.multiple.png new file mode 100644 index 000000000..8f31ec369 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.multiple.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.outside.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.outside.html new file mode 100644 index 000000000..7577c95e3 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.outside.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.gradient.interpolate.outside + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                            2d.gradient.interpolate.outside

                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.overlap.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.overlap.html new file mode 100644 index 000000000..ad2152f12 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.overlap.html @@ -0,0 +1,52 @@ + + +Canvas test: 2d.gradient.interpolate.overlap + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                              2d.gradient.interpolate.overlap

                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.overlap.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.overlap.png new file mode 100644 index 000000000..7d4dad8de Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.overlap.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.overlap2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.overlap2.html new file mode 100644 index 000000000..7f99c1f32 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.overlap2.html @@ -0,0 +1,42 @@ + + +Canvas test: 2d.gradient.interpolate.overlap2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                2d.gradient.interpolate.overlap2

                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.solid.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.solid.html new file mode 100644 index 000000000..46e53d326 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.solid.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.gradient.interpolate.solid + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                  2d.gradient.interpolate.solid

                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.vertical.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.vertical.html new file mode 100644 index 000000000..a4c3453cf --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.vertical.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.gradient.interpolate.vertical + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                    2d.gradient.interpolate.vertical

                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.vertical.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.vertical.png new file mode 100644 index 000000000..1d895a18f Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.vertical.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.fill.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.fill.html new file mode 100644 index 000000000..92777bfef --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.fill.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.gradient.interpolate.zerosize.fill + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                      2d.gradient.interpolate.zerosize.fill

                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.fillRect.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.fillRect.html new file mode 100644 index 000000000..98efeda7c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.fillRect.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.gradient.interpolate.zerosize.fillRect + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                        2d.gradient.interpolate.zerosize.fillRect

                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.fillText.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.fillText.html new file mode 100644 index 000000000..93397b976 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.fillText.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.gradient.interpolate.zerosize.fillText + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                          2d.gradient.interpolate.zerosize.fillText

                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.stroke.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.stroke.html new file mode 100644 index 000000000..69e2de6f4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.stroke.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.gradient.interpolate.zerosize.stroke + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                            2d.gradient.interpolate.zerosize.stroke

                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.strokeRect.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.strokeRect.html new file mode 100644 index 000000000..7eff74d80 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.strokeRect.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.gradient.interpolate.zerosize.strokeRect + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                              2d.gradient.interpolate.zerosize.strokeRect

                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.strokeText.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.strokeText.html new file mode 100644 index 000000000..d384cc01d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.strokeText.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.gradient.interpolate.zerosize.strokeText + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                2d.gradient.interpolate.zerosize.strokeText

                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.linear.nonfinite.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.linear.nonfinite.html new file mode 100644 index 000000000..b60b30438 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.linear.nonfinite.html @@ -0,0 +1,49 @@ + + +Canvas test: 2d.gradient.linear.nonfinite + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.gradient.linear.nonfinite

                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                  createLinearGradient() throws TypeError if arguments are not finite

                                                                                                                                                                                                                                                                                                                                                                                                                                  + +

                                                                                                                                                                                                                                                                                                                                                                                                                                  Defined in "Web IDL" (draft) +

                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                  + +
                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.linear.transform.1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.linear.transform.1.html new file mode 100644 index 000000000..3a4d24a39 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.linear.transform.1.html @@ -0,0 +1,37 @@ + + +Canvas test: 2d.gradient.linear.transform.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.gradient.linear.transform.1

                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                    Linear gradient coordinates are relative to the coordinate space at the time of filling

                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.linear.transform.2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.linear.transform.2.html new file mode 100644 index 000000000..56957a0a2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.linear.transform.2.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.gradient.linear.transform.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.gradient.linear.transform.2

                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                      Linear gradient coordinates are relative to the coordinate space at the time of filling

                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.linear.transform.3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.linear.transform.3.html new file mode 100644 index 000000000..6cc2ead2f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.linear.transform.3.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.gradient.linear.transform.3 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.gradient.linear.transform.3

                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                        Linear gradient transforms do not experience broken caching effects

                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.compare.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.compare.html new file mode 100644 index 000000000..67089a073 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.compare.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.gradient.object.compare + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.gradient.object.compare

                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                          + +
                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.crosscanvas.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.crosscanvas.html new file mode 100644 index 000000000..95144c6af --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.crosscanvas.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.gradient.object.crosscanvas + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.gradient.object.crosscanvas

                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.current.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.current.html new file mode 100644 index 000000000..35709cbd1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.current.html @@ -0,0 +1,37 @@ + + +Canvas test: 2d.gradient.object.current + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.gradient.object.current

                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.current.png b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.current.png new file mode 100644 index 000000000..d638d0338 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.current.png differ diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.invalidcolour.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.invalidcolour.html new file mode 100644 index 000000000..7687d0b94 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.invalidcolour.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.gradient.object.invalidcolour + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.gradient.object.invalidcolour

                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.invalidoffset.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.invalidoffset.html new file mode 100644 index 000000000..2dce28b66 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.invalidoffset.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.gradient.object.invalidoffset + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.gradient.object.invalidoffset

                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                  + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.return.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.return.html new file mode 100644 index 000000000..bcb4dc7af --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.return.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.gradient.object.return + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.gradient.object.return

                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                    createLinearGradient() and createRadialGradient() returns objects implementing CanvasGradient

                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.type.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.type.html new file mode 100644 index 000000000..27c91312c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.type.html @@ -0,0 +1,28 @@ + + +Canvas test: 2d.gradient.object.type + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.gradient.object.type

                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                      window.CanvasGradient exists and has the right properties

                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                      Defined in "Web IDL" (draft) +

                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.update.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.update.html new file mode 100644 index 000000000..8151c42f9 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.object.update.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.gradient.object.update + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.gradient.object.update

                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.behind.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.behind.html new file mode 100644 index 000000000..5bf367ea0 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.behind.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.gradient.radial.cone.behind + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.gradient.radial.cone.behind

                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.beside.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.beside.html new file mode 100644 index 000000000..6c7dbaa2a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.beside.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.gradient.radial.cone.beside + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.gradient.radial.cone.beside

                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.bottom.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.bottom.html new file mode 100644 index 000000000..362d23293 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.bottom.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.gradient.radial.cone.bottom + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.gradient.radial.cone.bottom

                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.cylinder.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.cylinder.html new file mode 100644 index 000000000..a2f189d83 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.cylinder.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.gradient.radial.cone.cylinder + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.gradient.radial.cone.cylinder

                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.front.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.front.html new file mode 100644 index 000000000..3ed6190b2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.front.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.gradient.radial.cone.front + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.gradient.radial.cone.front

                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.shape1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.shape1.html new file mode 100644 index 000000000..992c06805 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.shape1.html @@ -0,0 +1,53 @@ + + +Canvas test: 2d.gradient.radial.cone.shape1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.gradient.radial.cone.shape1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.shape2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.shape2.html new file mode 100644 index 000000000..cf9bd6d42 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.shape2.html @@ -0,0 +1,53 @@ + + +Canvas test: 2d.gradient.radial.cone.shape2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.gradient.radial.cone.shape2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.top.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.top.html new file mode 100644 index 000000000..fa60a0cfc --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.cone.top.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.gradient.radial.cone.top + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.gradient.radial.cone.top

                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.equal.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.equal.html new file mode 100644 index 000000000..f96b9761c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.equal.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.gradient.radial.equal + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.gradient.radial.equal

                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.inside1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.inside1.html new file mode 100644 index 000000000..ab656ce27 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.inside1.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.gradient.radial.inside1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.gradient.radial.inside1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.inside2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.inside2.html new file mode 100644 index 000000000..30f4c49b8 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.inside2.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.gradient.radial.inside2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.gradient.radial.inside2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.inside3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.inside3.html new file mode 100644 index 000000000..56c12a5b8 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.inside3.html @@ -0,0 +1,45 @@ + + +Canvas test: 2d.gradient.radial.inside3 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.gradient.radial.inside3

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.negative.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.negative.html new file mode 100644 index 000000000..29242165f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.negative.html @@ -0,0 +1,29 @@ + + +Canvas test: 2d.gradient.radial.negative + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.gradient.radial.negative

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  createRadialGradient() throws INDEX_SIZE_ERR if either radius is negative

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.nonfinite.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.nonfinite.html new file mode 100644 index 000000000..e12d5142a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.nonfinite.html @@ -0,0 +1,101 @@ + + +Canvas test: 2d.gradient.radial.nonfinite + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.gradient.radial.nonfinite

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    createRadialGradient() throws TypeError if arguments are not finite

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Defined in "Web IDL" (draft) +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.outside1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.outside1.html new file mode 100644 index 000000000..e2c68d66b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.outside1.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.gradient.radial.outside1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.gradient.radial.outside1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.outside2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.outside2.html new file mode 100644 index 000000000..254db4574 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.outside2.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.gradient.radial.outside2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.gradient.radial.outside2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.outside3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.outside3.html new file mode 100644 index 000000000..4324bc717 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.outside3.html @@ -0,0 +1,45 @@ + + +Canvas test: 2d.gradient.radial.outside3 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.gradient.radial.outside3

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.touch1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.touch1.html new file mode 100644 index 000000000..5e42c4094 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.touch1.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.gradient.radial.touch1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.gradient.radial.touch1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.touch2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.touch2.html new file mode 100644 index 000000000..37dfd5ea8 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.touch2.html @@ -0,0 +1,46 @@ + + +Canvas test: 2d.gradient.radial.touch2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.gradient.radial.touch2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.touch3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.touch3.html new file mode 100644 index 000000000..e401d19b4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.touch3.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.gradient.radial.touch3 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.gradient.radial.touch3

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.transform.1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.transform.1.html new file mode 100644 index 000000000..92355825e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.transform.1.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.gradient.radial.transform.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.gradient.radial.transform.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Radial gradient coordinates are relative to the coordinate space at the time of filling

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.transform.2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.transform.2.html new file mode 100644 index 000000000..ce7841f3b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.transform.2.html @@ -0,0 +1,39 @@ + + +Canvas test: 2d.gradient.radial.transform.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.gradient.radial.transform.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Radial gradient coordinates are relative to the coordinate space at the time of filling

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.transform.3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.transform.3.html new file mode 100644 index 000000000..ee9e6303b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.gradient.radial.transform.3.html @@ -0,0 +1,39 @@ + + +Canvas test: 2d.gradient.radial.transform.3 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.gradient.radial.transform.3

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Radial gradient transforms do not experience broken caching effects

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.animated.gif.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.animated.gif.html new file mode 100644 index 000000000..c78ef377b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.animated.gif.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.pattern.animated.gif + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.pattern.animated.gif

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        createPattern() of an animated GIF draws the first frame

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.basic.canvas.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.basic.canvas.html new file mode 100644 index 000000000..3bdc679c5 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.basic.canvas.html @@ -0,0 +1,49 @@ + + +Canvas test: 2d.pattern.basic.canvas + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.pattern.basic.canvas

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.basic.image.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.basic.image.html new file mode 100644 index 000000000..9ae64e4f5 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.basic.image.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.pattern.basic.image + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.pattern.basic.image

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.basic.nocontext.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.basic.nocontext.html new file mode 100644 index 000000000..a24958702 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.basic.nocontext.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.pattern.basic.nocontext + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.pattern.basic.nocontext

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.basic.type.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.basic.type.html new file mode 100644 index 000000000..07ca39923 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.basic.type.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.pattern.basic.type + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.pattern.basic.type

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.basic.zerocanvas.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.basic.zerocanvas.html new file mode 100644 index 000000000..aa393b8f7 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.basic.zerocanvas.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.pattern.basic.zerocanvas + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.pattern.basic.zerocanvas

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.crosscanvas.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.crosscanvas.html new file mode 100644 index 000000000..dc80720bb --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.crosscanvas.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.pattern.crosscanvas + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.pattern.crosscanvas

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.broken.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.broken.html new file mode 100644 index 000000000..31c8e8f2a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.broken.html @@ -0,0 +1,29 @@ + + +Canvas test: 2d.pattern.image.broken + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.pattern.image.broken

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.incomplete.emptysrc.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.incomplete.emptysrc.html new file mode 100644 index 000000000..23f453ac1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.incomplete.emptysrc.html @@ -0,0 +1,30 @@ + + +Canvas test: 2d.pattern.image.incomplete.emptysrc + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.pattern.image.incomplete.emptysrc

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.incomplete.immediate.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.incomplete.immediate.html new file mode 100644 index 000000000..176cf722a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.incomplete.immediate.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.pattern.image.incomplete.immediate + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.pattern.image.incomplete.immediate

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.incomplete.nosrc.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.incomplete.nosrc.html new file mode 100644 index 000000000..88b8801b2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.incomplete.nosrc.html @@ -0,0 +1,28 @@ + + +Canvas test: 2d.pattern.image.incomplete.nosrc + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.pattern.image.incomplete.nosrc

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.incomplete.reload.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.incomplete.reload.html new file mode 100644 index 000000000..095055c21 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.incomplete.reload.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.pattern.image.incomplete.reload + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.pattern.image.incomplete.reload

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.incomplete.removedsrc.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.incomplete.removedsrc.html new file mode 100644 index 000000000..514f0609c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.incomplete.removedsrc.html @@ -0,0 +1,30 @@ + + +Canvas test: 2d.pattern.image.incomplete.removedsrc + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.pattern.image.incomplete.removedsrc

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.null.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.null.html new file mode 100644 index 000000000..5b8c68817 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.null.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.pattern.image.null + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.pattern.image.null

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Defined in "Web IDL" (draft) +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.string.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.string.html new file mode 100644 index 000000000..834d92187 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.string.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.pattern.image.string + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.pattern.image.string

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Defined in "Web IDL" (draft) +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.undefined.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.undefined.html new file mode 100644 index 000000000..24f650d97 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.image.undefined.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.pattern.image.undefined + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.pattern.image.undefined

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Defined in "Web IDL" (draft) +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.modify.canvas1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.modify.canvas1.html new file mode 100644 index 000000000..f60da5bac --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.modify.canvas1.html @@ -0,0 +1,45 @@ + + +Canvas test: 2d.pattern.modify.canvas1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.pattern.modify.canvas1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.modify.canvas2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.modify.canvas2.html new file mode 100644 index 000000000..db7a8b842 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.modify.canvas2.html @@ -0,0 +1,49 @@ + + +Canvas test: 2d.pattern.modify.canvas2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.pattern.modify.canvas2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.modify.image1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.modify.image1.html new file mode 100644 index 000000000..cfc8a965d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.modify.image1.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.pattern.modify.image1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.pattern.modify.image1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.modify.image2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.modify.image2.html new file mode 100644 index 000000000..c7f2ee3bf --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.modify.image2.html @@ -0,0 +1,45 @@ + + +Canvas test: 2d.pattern.modify.image2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.pattern.modify.image2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.norepeat.basic.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.norepeat.basic.html new file mode 100644 index 000000000..431437e5b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.norepeat.basic.html @@ -0,0 +1,39 @@ + + +Canvas test: 2d.pattern.paint.norepeat.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.pattern.paint.norepeat.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.norepeat.coord1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.norepeat.coord1.html new file mode 100644 index 000000000..a560fd8dc --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.norepeat.coord1.html @@ -0,0 +1,42 @@ + + +Canvas test: 2d.pattern.paint.norepeat.coord1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.pattern.paint.norepeat.coord1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.norepeat.coord2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.norepeat.coord2.html new file mode 100644 index 000000000..9ae289872 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.norepeat.coord2.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.pattern.paint.norepeat.coord2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.pattern.paint.norepeat.coord2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.norepeat.coord3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.norepeat.coord3.html new file mode 100644 index 000000000..9c1b5ae6d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.norepeat.coord3.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.pattern.paint.norepeat.coord3 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.pattern.paint.norepeat.coord3

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.norepeat.outside.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.norepeat.outside.html new file mode 100644 index 000000000..3dce7a686 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.norepeat.outside.html @@ -0,0 +1,45 @@ + + +Canvas test: 2d.pattern.paint.norepeat.outside + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.pattern.paint.norepeat.outside

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.orientation.canvas.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.orientation.canvas.html new file mode 100644 index 000000000..70966e00a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.orientation.canvas.html @@ -0,0 +1,48 @@ + + +Canvas test: 2d.pattern.paint.orientation.canvas + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.pattern.paint.orientation.canvas

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Canvas patterns do not get flipped when painted

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.orientation.image.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.orientation.image.html new file mode 100644 index 000000000..7d109c55a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.orientation.image.html @@ -0,0 +1,45 @@ + + +Canvas test: 2d.pattern.paint.orientation.image + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.pattern.paint.orientation.image

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Image patterns do not get flipped when painted

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeat.basic.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeat.basic.html new file mode 100644 index 000000000..501fe67e4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeat.basic.html @@ -0,0 +1,39 @@ + + +Canvas test: 2d.pattern.paint.repeat.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.pattern.paint.repeat.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeat.coord1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeat.coord1.html new file mode 100644 index 000000000..4aa75d155 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeat.coord1.html @@ -0,0 +1,40 @@ + + +Canvas test: 2d.pattern.paint.repeat.coord1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.pattern.paint.repeat.coord1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeat.coord2.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeat.coord2.html new file mode 100644 index 000000000..0fe8b6a56 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeat.coord2.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.pattern.paint.repeat.coord2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.pattern.paint.repeat.coord2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeat.coord3.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeat.coord3.html new file mode 100644 index 000000000..b361c91f2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeat.coord3.html @@ -0,0 +1,39 @@ + + +Canvas test: 2d.pattern.paint.repeat.coord3 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.pattern.paint.repeat.coord3

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeat.outside.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeat.outside.html new file mode 100644 index 000000000..68d2fe84e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeat.outside.html @@ -0,0 +1,40 @@ + + +Canvas test: 2d.pattern.paint.repeat.outside + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.pattern.paint.repeat.outside

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeatx.basic.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeatx.basic.html new file mode 100644 index 000000000..3cec292a4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeatx.basic.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.pattern.paint.repeatx.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.pattern.paint.repeatx.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeatx.coord1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeatx.coord1.html new file mode 100644 index 000000000..1e864a729 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeatx.coord1.html @@ -0,0 +1,45 @@ + + +Canvas test: 2d.pattern.paint.repeatx.coord1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.pattern.paint.repeatx.coord1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeatx.outside.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeatx.outside.html new file mode 100644 index 000000000..074c4afa4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeatx.outside.html @@ -0,0 +1,42 @@ + + +Canvas test: 2d.pattern.paint.repeatx.outside + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.pattern.paint.repeatx.outside

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeaty.basic.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeaty.basic.html new file mode 100644 index 000000000..0da99d28d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeaty.basic.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.pattern.paint.repeaty.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.pattern.paint.repeaty.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeaty.coord1.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeaty.coord1.html new file mode 100644 index 000000000..2f42a4e2d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeaty.coord1.html @@ -0,0 +1,45 @@ + + +Canvas test: 2d.pattern.paint.repeaty.coord1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.pattern.paint.repeaty.coord1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeaty.outside.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeaty.outside.html new file mode 100644 index 000000000..9ec618a9d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.paint.repeaty.outside.html @@ -0,0 +1,42 @@ + + +Canvas test: 2d.pattern.paint.repeaty.outside + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.pattern.paint.repeaty.outside

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.case.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.case.html new file mode 100644 index 000000000..5a4bf344b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.case.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.pattern.repeat.case + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.pattern.repeat.case

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.empty.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.empty.html new file mode 100644 index 000000000..a71908721 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.empty.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.pattern.repeat.empty + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.pattern.repeat.empty

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.null.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.null.html new file mode 100644 index 000000000..25caf6c2e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.null.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.pattern.repeat.null + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.pattern.repeat.null

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.nullsuffix.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.nullsuffix.html new file mode 100644 index 000000000..371304204 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.nullsuffix.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.pattern.repeat.nullsuffix + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.pattern.repeat.nullsuffix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.undefined.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.undefined.html new file mode 100644 index 000000000..74cd84b33 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.undefined.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.pattern.repeat.undefined + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.pattern.repeat.undefined

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.unrecognised.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.unrecognised.html new file mode 100644 index 000000000..ff4d50a73 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.unrecognised.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.pattern.repeat.unrecognised + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.pattern.repeat.unrecognised

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.unrecognisednull.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.unrecognisednull.html new file mode 100644 index 000000000..57df03be6 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.pattern.repeat.unrecognisednull.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.pattern.repeat.unrecognisednull + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.pattern.repeat.unrecognisednull

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.strokeStyle.default.html b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.strokeStyle.default.html new file mode 100644 index 000000000..6e07d6086 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/2d.strokeStyle.default.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.strokeStyle.default + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.strokeStyle.default

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/canvas_colorsandstyles_createlineargradient_001.htm b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/canvas_colorsandstyles_createlineargradient_001.htm new file mode 100644 index 000000000..5b77c98de --- /dev/null +++ b/testing/web-platform/tests/2dcontext/fill-and-stroke-styles/canvas_colorsandstyles_createlineargradient_001.htm @@ -0,0 +1,59 @@ + + + + HTML5 Canvas Test: createlinearGradient() with two points same + + + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Description: If the two points in a linear gradient have identical x,y coordinates, the canvas must paint nothing.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Test passes if there is one left-to-right, green-to-blue linear gradient seen on the page and no red is seen on the page.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + Browser does not support HTML5 Canvas. + + diff --git a/testing/web-platform/tests/2dcontext/green-100x50.png b/testing/web-platform/tests/2dcontext/green-100x50.png new file mode 100644 index 000000000..2733836c9 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/green-100x50.png differ diff --git a/testing/web-platform/tests/2dcontext/hit-regions/.gitkeep b/testing/web-platform/tests/2dcontext/hit-regions/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/testing/web-platform/tests/2dcontext/hit-regions/addHitRegions-NotSupportedError-01.html b/testing/web-platform/tests/2dcontext/hit-regions/addHitRegions-NotSupportedError-01.html new file mode 100644 index 000000000..05818aeb8 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/hit-regions/addHitRegions-NotSupportedError-01.html @@ -0,0 +1,89 @@ + + + + +Hit regions: addHitRegion throws NotSupportedError + + + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + + + diff --git a/testing/web-platform/tests/2dcontext/hit-regions/hitregions-members-exist.html b/testing/web-platform/tests/2dcontext/hit-regions/hitregions-members-exist.html new file mode 100644 index 000000000..b9203f560 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/hit-regions/hitregions-members-exist.html @@ -0,0 +1,29 @@ + +Canvas test: 2d.hitregions.members.exist + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.hitregions.members.exist

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + + \ No newline at end of file diff --git a/testing/web-platform/tests/2dcontext/image-smoothing/imagesmoothing.html b/testing/web-platform/tests/2dcontext/image-smoothing/imagesmoothing.html new file mode 100644 index 000000000..1a86a8f20 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/image-smoothing/imagesmoothing.html @@ -0,0 +1,119 @@ + + +CanvasRenderingContext2D imageSmoothingEnabled test + + + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/.gitkeep b/testing/web-platform/tests/2dcontext/line-styles/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.butt.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.butt.html new file mode 100644 index 000000000..353676233 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.butt.html @@ -0,0 +1,61 @@ + + +Canvas test: 2d.line.cap.butt + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.line.cap.butt

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    lineCap 'butt' is rendered correctly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.closed.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.closed.html new file mode 100644 index 000000000..f8e233a41 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.closed.html @@ -0,0 +1,46 @@ + + +Canvas test: 2d.line.cap.closed + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.line.cap.closed

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Line caps are not drawn at the corners of an unclosed rectangle

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.invalid.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.invalid.html new file mode 100644 index 000000000..1db32a9d6 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.invalid.html @@ -0,0 +1,52 @@ + + +Canvas test: 2d.line.cap.invalid + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.line.cap.invalid

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Setting lineCap to invalid values is ignored

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.open.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.open.html new file mode 100644 index 000000000..499773085 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.open.html @@ -0,0 +1,46 @@ + + +Canvas test: 2d.line.cap.open + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.line.cap.open

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Line caps are drawn at the corners of an unclosed rectangle

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.round.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.round.html new file mode 100644 index 000000000..675d11ce2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.round.html @@ -0,0 +1,77 @@ + + +Canvas test: 2d.line.cap.round + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.line.cap.round

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            lineCap 'round' is rendered correctly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.square.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.square.html new file mode 100644 index 000000000..ea1e4d949 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.square.html @@ -0,0 +1,61 @@ + + +Canvas test: 2d.line.cap.square + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.line.cap.square

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              lineCap 'square' is rendered correctly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.valid.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.valid.html new file mode 100644 index 000000000..6ac119d4a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.cap.valid.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.line.cap.valid + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.line.cap.valid

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Setting lineCap to valid values works

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.cross.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.cross.html new file mode 100644 index 000000000..61b2125c4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.cross.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.line.cross + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.line.cross

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.defaults.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.defaults.html new file mode 100644 index 000000000..8b680785d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.defaults.html @@ -0,0 +1,30 @@ + + +Canvas test: 2d.line.defaults + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.line.defaults

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.bevel.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.bevel.html new file mode 100644 index 000000000..72c0186e1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.bevel.html @@ -0,0 +1,80 @@ + + +Canvas test: 2d.line.join.bevel + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.line.join.bevel

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      lineJoin 'bevel' is rendered correctly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.closed.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.closed.html new file mode 100644 index 000000000..1f2bf5cb7 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.closed.html @@ -0,0 +1,45 @@ + + +Canvas test: 2d.line.join.closed + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.line.join.closed

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Line joins are drawn at the corner of a closed rectangle

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.invalid.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.invalid.html new file mode 100644 index 000000000..9d54d90b1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.invalid.html @@ -0,0 +1,52 @@ + + +Canvas test: 2d.line.join.invalid + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.line.join.invalid

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Setting lineJoin to invalid values is ignored

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.miter.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.miter.html new file mode 100644 index 000000000..8a6d4a60e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.miter.html @@ -0,0 +1,71 @@ + + +Canvas test: 2d.line.join.miter + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.line.join.miter

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            lineJoin 'miter' is rendered correctly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.open.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.open.html new file mode 100644 index 000000000..a72291bc3 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.open.html @@ -0,0 +1,45 @@ + + +Canvas test: 2d.line.join.open + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.line.join.open

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Line joins are not drawn at the corner of an unclosed rectangle

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.parallel.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.parallel.html new file mode 100644 index 000000000..2a8956d7e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.parallel.html @@ -0,0 +1,42 @@ + + +Canvas test: 2d.line.join.parallel + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.line.join.parallel

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Line joins are drawn at 180-degree joins

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.round.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.round.html new file mode 100644 index 000000000..4a827adce --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.round.html @@ -0,0 +1,78 @@ + + +Canvas test: 2d.line.join.round + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.line.join.round

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  lineJoin 'round' is rendered correctly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.valid.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.valid.html new file mode 100644 index 000000000..98fec4cb7 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.join.valid.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.line.join.valid + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.line.join.valid

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Setting lineJoin to valid values works

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.acute.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.acute.html new file mode 100644 index 000000000..f11a32164 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.acute.html @@ -0,0 +1,52 @@ + + +Canvas test: 2d.line.miter.acute + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.line.miter.acute

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Miter joins are drawn correctly with acute angles

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.exceeded.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.exceeded.html new file mode 100644 index 000000000..1cbcd3cad --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.exceeded.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.line.miter.exceeded + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.line.miter.exceeded

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Miter joins are not drawn when the miter limit is exceeded

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.invalid.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.invalid.html new file mode 100644 index 000000000..4f7fd69bc --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.invalid.html @@ -0,0 +1,48 @@ + + +Canvas test: 2d.line.miter.invalid + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.line.miter.invalid

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Setting miterLimit to invalid values is ignored

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.lineedge.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.lineedge.html new file mode 100644 index 000000000..54c2ce539 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.lineedge.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.line.miter.lineedge + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.line.miter.lineedge

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Miter joins are not drawn when the miter limit is exceeded at the corners of a zero-height rectangle

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.obtuse.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.obtuse.html new file mode 100644 index 000000000..40ebdd1f8 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.obtuse.html @@ -0,0 +1,52 @@ + + +Canvas test: 2d.line.miter.obtuse + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.line.miter.obtuse

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Miter joins are drawn correctly with obtuse angles

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.rightangle.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.rightangle.html new file mode 100644 index 000000000..ebcfb261a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.rightangle.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.line.miter.rightangle + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.line.miter.rightangle

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Miter joins are not drawn when the miter limit is exceeded, on exact right angles

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.valid.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.valid.html new file mode 100644 index 000000000..59148aa56 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.valid.html @@ -0,0 +1,37 @@ + + +Canvas test: 2d.line.miter.valid + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.line.miter.valid

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Setting miterLimit to valid values works

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.within.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.within.html new file mode 100644 index 000000000..5ed57e0cc --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.miter.within.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.line.miter.within + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.line.miter.within

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Miter joins are drawn when the miter limit is not quite exceeded

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.union.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.union.html new file mode 100644 index 000000000..92fa2f1a2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.union.html @@ -0,0 +1,46 @@ + + +Canvas test: 2d.line.union + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.line.union

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.width.basic.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.width.basic.html new file mode 100644 index 000000000..b61baaf24 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.width.basic.html @@ -0,0 +1,63 @@ + + +Canvas test: 2d.line.width.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.line.width.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        lineWidth determines the width of line strokes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.width.invalid.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.width.invalid.html new file mode 100644 index 000000000..d5cd3ab0a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.width.invalid.html @@ -0,0 +1,48 @@ + + +Canvas test: 2d.line.width.invalid + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.line.width.invalid

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Setting lineWidth to invalid values is ignored

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.width.scaledefault.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.width.scaledefault.html new file mode 100644 index 000000000..154d7b582 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.width.scaledefault.html @@ -0,0 +1,40 @@ + + +Canvas test: 2d.line.width.scaledefault + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.line.width.scaledefault

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Default lineWidth strokes are affected by scale transformations

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.width.transformed.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.width.transformed.html new file mode 100644 index 000000000..903321f44 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.width.transformed.html @@ -0,0 +1,69 @@ + + +Canvas test: 2d.line.width.transformed + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.line.width.transformed

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Line stroke widths are affected by scale transformations

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/2d.line.width.valid.html b/testing/web-platform/tests/2dcontext/line-styles/2d.line.width.valid.html new file mode 100644 index 000000000..c89fa56a6 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/2d.line.width.valid.html @@ -0,0 +1,37 @@ + + +Canvas test: 2d.line.width.valid + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.line.width.valid

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Setting lineWidth to valid values works

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/canvas_linestyles_linecap_001-ref.htm b/testing/web-platform/tests/2dcontext/line-styles/canvas_linestyles_linecap_001-ref.htm new file mode 100644 index 000000000..f85af9aab --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/canvas_linestyles_linecap_001-ref.htm @@ -0,0 +1,11 @@ + + + + HTML5 Canvas Test: "square" lineCap + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Description: The square value of lineCap means that a rectangle with the length of the line width and the width of half the line width, placed flat against the edge perpendicular to the direction of the line, must be added at the end of each line.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  black rect
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/canvas_linestyles_linecap_001.htm b/testing/web-platform/tests/2dcontext/line-styles/canvas_linestyles_linecap_001.htm new file mode 100644 index 000000000..583dbc9d1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/canvas_linestyles_linecap_001.htm @@ -0,0 +1,37 @@ + + + + HTML5 Canvas Test: "square" lineCap + + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Description: The square value of lineCap means that a rectangle with the length of the line width and the width of half the line width, placed flat against the edge perpendicular to the direction of the line, must be added at the end of each line.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + Browser does not support HTML5 Canvas. + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/lineto_a.html b/testing/web-platform/tests/2dcontext/line-styles/lineto_a.html new file mode 100644 index 000000000..7e692f937 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/lineto_a.html @@ -0,0 +1,26 @@ + + + + + +Your browser does not support the HTML5 canvas tag. + + diff --git a/testing/web-platform/tests/2dcontext/line-styles/lineto_ref.html b/testing/web-platform/tests/2dcontext/line-styles/lineto_ref.html new file mode 100644 index 000000000..3dc78ff80 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/lineto_ref.html @@ -0,0 +1,15 @@ + + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  diff --git a/testing/web-platform/tests/2dcontext/line-styles/setLineDash.html b/testing/web-platform/tests/2dcontext/line-styles/setLineDash.html new file mode 100644 index 000000000..06fcada76 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/line-styles/setLineDash.html @@ -0,0 +1,104 @@ + + +setLineDash + + + + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/.gitkeep b/testing/web-platform/tests/2dcontext/path-objects/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.1.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.1.html new file mode 100644 index 000000000..06ac1665d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.1.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.arc.angle.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.path.arc.angle.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  arc() draws pi/2 .. -pi anticlockwise correctly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.2.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.2.html new file mode 100644 index 000000000..328756cce --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.2.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.arc.angle.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.path.arc.angle.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    arc() draws -3pi/2 .. -pi anticlockwise correctly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.3.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.3.html new file mode 100644 index 000000000..a0696d625 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.3.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.arc.angle.3 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.path.arc.angle.3

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      arc() wraps angles mod 2pi when anticlockwise and end > start+2pi

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.4.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.4.html new file mode 100644 index 000000000..bad839d80 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.4.html @@ -0,0 +1,37 @@ + + +Canvas test: 2d.path.arc.angle.4 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.path.arc.angle.4

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        arc() draws a full circle when clockwise and end > start+2pi

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.5.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.5.html new file mode 100644 index 000000000..5a0534452 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.5.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.arc.angle.5 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.path.arc.angle.5

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          arc() wraps angles mod 2pi when clockwise and start > end+2pi

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.6.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.6.html new file mode 100644 index 000000000..3b645cb27 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.angle.6.html @@ -0,0 +1,37 @@ + + +Canvas test: 2d.path.arc.angle.6 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.path.arc.angle.6

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            arc() draws a full circle when anticlockwise and start > end+2pi

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.default.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.default.html new file mode 100644 index 000000000..3ccfd9914 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.default.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.arc.default + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.path.arc.default

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              arc() with missing last argument defaults to clockwise

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.empty.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.empty.html new file mode 100644 index 000000000..fa59b66f5 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.empty.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.arc.empty + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.path.arc.empty

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                arc() with an empty path does not draw a straight line to the start point

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.end.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.end.html new file mode 100644 index 000000000..13b1188d1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.end.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.path.arc.end + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.path.arc.end

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  arc() adds the end point of the arc to the subpath

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.negative.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.negative.html new file mode 100644 index 000000000..c82769046 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.negative.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.path.arc.negative + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.path.arc.negative

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    arc() with negative radius throws INDEX_SIZE_ERR

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.nonempty.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.nonempty.html new file mode 100644 index 000000000..ffc0b8c0c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.nonempty.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.path.arc.nonempty + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.path.arc.nonempty

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      arc() with a non-empty path does draw a straight line to the start point

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.nonfinite.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.nonfinite.html new file mode 100644 index 000000000..d8cffe446 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.nonfinite.html @@ -0,0 +1,77 @@ + + +Canvas test: 2d.path.arc.nonfinite + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.path.arc.nonfinite

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        arc() with Infinity/NaN is ignored

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.scale.1.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.scale.1.html new file mode 100644 index 000000000..fcb2b52ae --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.scale.1.html @@ -0,0 +1,54 @@ + + +Canvas test: 2d.path.arc.scale.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.path.arc.scale.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Non-uniformly scaled arcs are the right shape

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.scale.2.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.scale.2.html new file mode 100644 index 000000000..59d182c92 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.scale.2.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.path.arc.scale.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.path.arc.scale.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Highly scaled arcs are the right shape

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.selfintersect.1.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.selfintersect.1.html new file mode 100644 index 000000000..e212b49b4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.selfintersect.1.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.path.arc.selfintersect.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.path.arc.selfintersect.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              arc() with lineWidth > 2*radius is drawn sensibly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.selfintersect.2.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.selfintersect.2.html new file mode 100644 index 000000000..8bc9fea70 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.selfintersect.2.html @@ -0,0 +1,42 @@ + + +Canvas test: 2d.path.arc.selfintersect.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.path.arc.selfintersect.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                arc() with lineWidth > 2*radius is drawn sensibly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.shape.1.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.shape.1.html new file mode 100644 index 000000000..dcaac9bb1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.shape.1.html @@ -0,0 +1,39 @@ + + +Canvas test: 2d.path.arc.shape.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.path.arc.shape.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  arc() from 0 to pi does not draw anything in the wrong half

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.shape.2.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.shape.2.html new file mode 100644 index 000000000..dee4b3841 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.shape.2.html @@ -0,0 +1,39 @@ + + +Canvas test: 2d.path.arc.shape.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.path.arc.shape.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    arc() from 0 to pi draws stuff in the right half

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.shape.3.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.shape.3.html new file mode 100644 index 000000000..0090411fa --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.shape.3.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.path.arc.shape.3 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.path.arc.shape.3

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      arc() from 0 to -pi/2 does not draw anything in the wrong quadrant

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.shape.4.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.shape.4.html new file mode 100644 index 000000000..dc12ef6c1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.shape.4.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.path.arc.shape.4 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.path.arc.shape.4

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        arc() from 0 to -pi/2 draws stuff in the right quadrant

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.shape.5.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.shape.5.html new file mode 100644 index 000000000..2a84dde74 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.shape.5.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.path.arc.shape.5 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.path.arc.shape.5

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          arc() from 0 to 5pi does not draw crazy things

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.twopie.1.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.twopie.1.html new file mode 100644 index 000000000..25fc393aa --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.twopie.1.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.arc.twopie.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.path.arc.twopie.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            arc() draws nothing when end = start + 2pi-e and anticlockwise

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.twopie.2.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.twopie.2.html new file mode 100644 index 000000000..775a87c22 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.twopie.2.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.arc.twopie.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.path.arc.twopie.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              arc() draws a full circle when end = start + 2pi-e and clockwise

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.twopie.3.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.twopie.3.html new file mode 100644 index 000000000..19680022f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.twopie.3.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.arc.twopie.3 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.path.arc.twopie.3

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                arc() draws a full circle when end = start + 2pi+e and anticlockwise

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.twopie.4.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.twopie.4.html new file mode 100644 index 000000000..bddf7fb49 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.twopie.4.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.arc.twopie.4 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.path.arc.twopie.4

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  arc() draws nothing when end = start + 2pi+e and clockwise

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.zero.1.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.zero.1.html new file mode 100644 index 000000000..e18a84919 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.zero.1.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.arc.zero.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.path.arc.zero.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    arc() draws nothing when startAngle = endAngle and anticlockwise

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.zero.2.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.zero.2.html new file mode 100644 index 000000000..398a74d2a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.zero.2.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.arc.zero.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.path.arc.zero.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      arc() draws nothing when startAngle = endAngle and clockwise

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.zeroradius.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.zeroradius.html new file mode 100644 index 000000000..af1ccf741 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arc.zeroradius.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.path.arc.zeroradius + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.path.arc.zeroradius

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        arc() with zero radius draws a line to the start point

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.coincide.1.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.coincide.1.html new file mode 100644 index 000000000..936034e38 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.coincide.1.html @@ -0,0 +1,46 @@ + + +Canvas test: 2d.path.arcTo.coincide.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.path.arcTo.coincide.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          arcTo() has no effect if P0 = P1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.coincide.2.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.coincide.2.html new file mode 100644 index 000000000..c64fa4c81 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.coincide.2.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.path.arcTo.coincide.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.path.arcTo.coincide.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            arcTo() draws a straight line to P1 if P1 = P2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.collinear.1.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.collinear.1.html new file mode 100644 index 000000000..196dbc445 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.collinear.1.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.path.arcTo.collinear.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.path.arcTo.collinear.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              arcTo() with all points on a line, and P1 between P0/P2, draws a straight line to P1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.collinear.2.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.collinear.2.html new file mode 100644 index 000000000..75998b308 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.collinear.2.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.path.arcTo.collinear.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.path.arcTo.collinear.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                arcTo() with all points on a line, and P2 between P0/P1, draws a straight line to P1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.collinear.3.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.collinear.3.html new file mode 100644 index 000000000..8a0e9a888 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.collinear.3.html @@ -0,0 +1,48 @@ + + +Canvas test: 2d.path.arcTo.collinear.3 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.path.arcTo.collinear.3

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  arcTo() with all points on a line, and P0 between P1/P2, draws a straight line to P1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.ensuresubpath.1.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.ensuresubpath.1.html new file mode 100644 index 000000000..cae097116 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.ensuresubpath.1.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.arcTo.ensuresubpath.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.path.arcTo.ensuresubpath.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    If there is no subpath, the first control point is added (and nothing is drawn up to it)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.ensuresubpath.2.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.ensuresubpath.2.html new file mode 100644 index 000000000..4d25a84f4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.ensuresubpath.2.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.path.arcTo.ensuresubpath.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.path.arcTo.ensuresubpath.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      If there is no subpath, the first control point is added

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.negative.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.negative.html new file mode 100644 index 000000000..5aa7baa4c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.negative.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.path.arcTo.negative + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.path.arcTo.negative

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        arcTo() with negative radius throws an exception

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.nonfinite.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.nonfinite.html new file mode 100644 index 000000000..354d62186 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.nonfinite.html @@ -0,0 +1,75 @@ + + +Canvas test: 2d.path.arcTo.nonfinite + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.path.arcTo.nonfinite

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          arcTo() with Infinity/NaN is ignored

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.scale.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.scale.html new file mode 100644 index 000000000..0de2336d7 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.scale.html @@ -0,0 +1,47 @@ + + +Canvas test: 2d.path.arcTo.scale + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.path.arcTo.scale

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            arcTo scales the curve, not just the control points

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.shape.curve1.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.shape.curve1.html new file mode 100644 index 000000000..fa06b5bd1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.shape.curve1.html @@ -0,0 +1,60 @@ + + +Canvas test: 2d.path.arcTo.shape.curve1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.path.arcTo.shape.curve1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              arcTo() curves in the right kind of shape

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.shape.curve2.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.shape.curve2.html new file mode 100644 index 000000000..ae0722c54 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.shape.curve2.html @@ -0,0 +1,59 @@ + + +Canvas test: 2d.path.arcTo.shape.curve2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.path.arcTo.shape.curve2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                arcTo() curves in the right kind of shape

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.shape.end.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.shape.end.html new file mode 100644 index 000000000..44137138b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.shape.end.html @@ -0,0 +1,40 @@ + + +Canvas test: 2d.path.arcTo.shape.end + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.path.arcTo.shape.end

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  arcTo() does not draw anything from P1 to P2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.shape.start.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.shape.start.html new file mode 100644 index 000000000..c7677af8d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.shape.start.html @@ -0,0 +1,40 @@ + + +Canvas test: 2d.path.arcTo.shape.start + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.path.arcTo.shape.start

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    arcTo() draws a straight line from P0 to P1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.transformation.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.transformation.html new file mode 100644 index 000000000..351495c38 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.transformation.html @@ -0,0 +1,46 @@ + + +Canvas test: 2d.path.arcTo.transformation + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.path.arcTo.transformation

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      arcTo joins up to the last subpath point correctly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.zero.1.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.zero.1.html new file mode 100644 index 000000000..fa172b5a9 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.zero.1.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.path.arcTo.zero.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.path.arcTo.zero.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        arcTo() with zero radius draws a straight line from P0 to P1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.zero.2.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.zero.2.html new file mode 100644 index 000000000..ede4480fd --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.arcTo.zero.2.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.path.arcTo.zero.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.path.arcTo.zero.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          arcTo() with zero radius draws a straight line from P0 to P1, even when all points are collinear

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.beginPath.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.beginPath.html new file mode 100644 index 000000000..86c7b0721 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.beginPath.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.path.beginPath + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.path.beginPath

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.basic.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.basic.html new file mode 100644 index 000000000..2628fee45 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.basic.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.path.bezierCurveTo.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.path.bezierCurveTo.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.ensuresubpath.1.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.ensuresubpath.1.html new file mode 100644 index 000000000..37f3c6a9a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.ensuresubpath.1.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.path.bezierCurveTo.ensuresubpath.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.path.bezierCurveTo.ensuresubpath.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If there is no subpath, the first control point is added (and nothing is drawn up to it)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.ensuresubpath.2.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.ensuresubpath.2.html new file mode 100644 index 000000000..4fd2a0e3c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.ensuresubpath.2.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.path.bezierCurveTo.ensuresubpath.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.path.bezierCurveTo.ensuresubpath.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  If there is no subpath, the first control point is added

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.nonfinite.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.nonfinite.html new file mode 100644 index 000000000..28639c657 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.nonfinite.html @@ -0,0 +1,109 @@ + + +Canvas test: 2d.path.bezierCurveTo.nonfinite + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.path.bezierCurveTo.nonfinite

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    bezierCurveTo() with Infinity/NaN is ignored

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.scaled.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.scaled.html new file mode 100644 index 000000000..6546d5d64 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.scaled.html @@ -0,0 +1,40 @@ + + +Canvas test: 2d.path.bezierCurveTo.scaled + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.path.bezierCurveTo.scaled

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.shape.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.shape.html new file mode 100644 index 000000000..26b502a98 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.bezierCurveTo.shape.html @@ -0,0 +1,39 @@ + + +Canvas test: 2d.path.bezierCurveTo.shape + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.path.bezierCurveTo.shape

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.basic.1.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.basic.1.html new file mode 100644 index 000000000..e15a0e3bb --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.basic.1.html @@ -0,0 +1,37 @@ + + +Canvas test: 2d.path.clip.basic.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.path.clip.basic.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.basic.2.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.basic.2.html new file mode 100644 index 000000000..65f9eff73 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.basic.2.html @@ -0,0 +1,37 @@ + + +Canvas test: 2d.path.clip.basic.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.path.clip.basic.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.empty.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.empty.html new file mode 100644 index 000000000..9a437b16e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.empty.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.path.clip.empty + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.path.clip.empty

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.intersect.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.intersect.html new file mode 100644 index 000000000..3ef64feb3 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.intersect.html @@ -0,0 +1,40 @@ + + +Canvas test: 2d.path.clip.intersect + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.path.clip.intersect

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.unaffected.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.unaffected.html new file mode 100644 index 000000000..606c34174 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.unaffected.html @@ -0,0 +1,42 @@ + + +Canvas test: 2d.path.clip.unaffected + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.path.clip.unaffected

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.winding.1.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.winding.1.html new file mode 100644 index 000000000..9fe007b40 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.winding.1.html @@ -0,0 +1,45 @@ + + +Canvas test: 2d.path.clip.winding.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.path.clip.winding.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.winding.2.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.winding.2.html new file mode 100644 index 000000000..dd9b6ad6c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.clip.winding.2.html @@ -0,0 +1,49 @@ + + +Canvas test: 2d.path.clip.winding.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.path.clip.winding.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.closePath.empty.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.closePath.empty.html new file mode 100644 index 000000000..8ee68dc83 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.closePath.empty.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.path.closePath.empty + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.path.closePath.empty

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.closePath.newline.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.closePath.newline.html new file mode 100644 index 000000000..391451e6f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.closePath.newline.html @@ -0,0 +1,37 @@ + + +Canvas test: 2d.path.closePath.newline + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.path.closePath.newline

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.closePath.nextpoint.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.closePath.nextpoint.html new file mode 100644 index 000000000..e98458b18 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.closePath.nextpoint.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.path.closePath.nextpoint + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.path.closePath.nextpoint

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.closed.basic.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.closed.basic.html new file mode 100644 index 000000000..b0fbee754 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.closed.basic.html @@ -0,0 +1,37 @@ + + +Canvas test: 2d.path.fill.closed.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.path.fill.closed.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.closed.unaffected.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.closed.unaffected.html new file mode 100644 index 000000000..a1d11287c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.closed.unaffected.html @@ -0,0 +1,40 @@ + + +Canvas test: 2d.path.fill.closed.unaffected + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.path.fill.closed.unaffected

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.overlap.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.overlap.html new file mode 100644 index 000000000..d69999c24 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.overlap.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.path.fill.overlap + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.path.fill.overlap

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.overlap.png b/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.overlap.png new file mode 100644 index 000000000..e2a35d48d Binary files /dev/null and b/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.overlap.png differ diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.winding.add.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.winding.add.html new file mode 100644 index 000000000..3eaa0f1bf --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.winding.add.html @@ -0,0 +1,42 @@ + + +Canvas test: 2d.path.fill.winding.add + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.path.fill.winding.add

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.winding.subtract.1.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.winding.subtract.1.html new file mode 100644 index 000000000..50a2a1dbb --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.winding.subtract.1.html @@ -0,0 +1,42 @@ + + +Canvas test: 2d.path.fill.winding.subtract.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.path.fill.winding.subtract.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.winding.subtract.2.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.winding.subtract.2.html new file mode 100644 index 000000000..b9423507c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.winding.subtract.2.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.path.fill.winding.subtract.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.path.fill.winding.subtract.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.winding.subtract.3.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.winding.subtract.3.html new file mode 100644 index 000000000..131672d10 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.fill.winding.subtract.3.html @@ -0,0 +1,47 @@ + + +Canvas test: 2d.path.fill.winding.subtract.3 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.path.fill.winding.subtract.3

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.initial.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.initial.html new file mode 100644 index 000000000..9dadad800 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.initial.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.path.initial + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.path.initial

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.arc.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.arc.html new file mode 100644 index 000000000..2d6cfcce5 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.arc.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.path.isPointInPath.arc + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.path.isPointInPath.arc

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              isPointInPath() works on arcs

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.basic.1.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.basic.1.html new file mode 100644 index 000000000..31818b0ad --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.basic.1.html @@ -0,0 +1,29 @@ + + +Canvas test: 2d.path.isPointInPath.basic.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.path.isPointInPath.basic.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                isPointInPath() detects whether the point is inside the path

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.basic.2.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.basic.2.html new file mode 100644 index 000000000..138368ec1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.basic.2.html @@ -0,0 +1,29 @@ + + +Canvas test: 2d.path.isPointInPath.basic.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.path.isPointInPath.basic.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  isPointInPath() detects whether the point is inside the path

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.bezier.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.bezier.html new file mode 100644 index 000000000..aa246f63c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.bezier.html @@ -0,0 +1,48 @@ + + +Canvas test: 2d.path.isPointInPath.bezier + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.path.isPointInPath.bezier

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    isPointInPath() works on Bezier curves

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.bigarc.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.bigarc.html new file mode 100644 index 000000000..1565aeeba --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.bigarc.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.path.isPointInPath.bigarc + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.path.isPointInPath.bigarc

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      isPointInPath() works on unclosed arcs larger than 2pi

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.edge.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.edge.html new file mode 100644 index 000000000..70faf8054 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.edge.html @@ -0,0 +1,39 @@ + + +Canvas test: 2d.path.isPointInPath.edge + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.path.isPointInPath.edge

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        isPointInPath() counts points on the path as being inside

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.empty.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.empty.html new file mode 100644 index 000000000..b1e4b2dbd --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.empty.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.path.isPointInPath.empty + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.path.isPointInPath.empty

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          isPointInPath() works when there is no path

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.nonfinite.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.nonfinite.html new file mode 100644 index 000000000..f70e66288 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.nonfinite.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.isPointInPath.nonfinite + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.path.isPointInPath.nonfinite

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            isPointInPath() returns false for non-finite arguments

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.outside.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.outside.html new file mode 100644 index 000000000..1abe32483 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.outside.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.isPointInPath.outside + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.path.isPointInPath.outside

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              isPointInPath() works on paths outside the canvas

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.subpath.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.subpath.html new file mode 100644 index 000000000..34bd0c776 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.subpath.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.isPointInPath.subpath + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.path.isPointInPath.subpath

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                isPointInPath() uses the current path, not just the subpath

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.transform.1.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.transform.1.html new file mode 100644 index 000000000..20777390c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.transform.1.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.isPointInPath.transform.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.path.isPointInPath.transform.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  isPointInPath() handles transformations correctly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.transform.2.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.transform.2.html new file mode 100644 index 000000000..bde026e4f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.transform.2.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.isPointInPath.transform.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.path.isPointInPath.transform.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    isPointInPath() handles transformations correctly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.transform.3.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.transform.3.html new file mode 100644 index 000000000..c612aae60 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.transform.3.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.isPointInPath.transform.3 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.path.isPointInPath.transform.3

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      isPointInPath() handles transformations correctly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.transform.4.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.transform.4.html new file mode 100644 index 000000000..50fc45d2f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.transform.4.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.path.isPointInPath.transform.4 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.path.isPointInPath.transform.4

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        isPointInPath() handles transformations correctly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.unclosed.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.unclosed.html new file mode 100644 index 000000000..a13759253 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.unclosed.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.path.isPointInPath.unclosed + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.path.isPointInPath.unclosed

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          isPointInPath() works on unclosed subpaths

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.winding.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.winding.html new file mode 100644 index 000000000..afa83810b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.isPointInPath.winding.html @@ -0,0 +1,47 @@ + + +Canvas test: 2d.path.isPointInPath.winding + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.path.isPointInPath.winding

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            isPointInPath() uses the non-zero winding number rule

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.basic.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.basic.html new file mode 100644 index 000000000..8606f8900 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.basic.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.path.lineTo.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.path.lineTo.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.ensuresubpath.1.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.ensuresubpath.1.html new file mode 100644 index 000000000..a4c0efb7e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.ensuresubpath.1.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.lineTo.ensuresubpath.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.path.lineTo.ensuresubpath.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If there is no subpath, the point is added and nothing is drawn

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.ensuresubpath.2.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.ensuresubpath.2.html new file mode 100644 index 000000000..94e6eddda --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.ensuresubpath.2.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.path.lineTo.ensuresubpath.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.path.lineTo.ensuresubpath.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  If there is no subpath, the point is added and used for subsequent drawing

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.nextpoint.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.nextpoint.html new file mode 100644 index 000000000..c2032f7c5 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.nextpoint.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.path.lineTo.nextpoint + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.path.lineTo.nextpoint

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.nonfinite.details.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.nonfinite.details.html new file mode 100644 index 000000000..88886ebe2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.nonfinite.details.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.path.lineTo.nonfinite.details + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.path.lineTo.nonfinite.details

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      lineTo() with Infinity/NaN for first arg still converts the second arg

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.nonfinite.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.nonfinite.html new file mode 100644 index 000000000..52982d2f6 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.lineTo.nonfinite.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.path.lineTo.nonfinite + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.path.lineTo.nonfinite

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        lineTo() with Infinity/NaN is ignored

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.moveTo.basic.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.moveTo.basic.html new file mode 100644 index 000000000..999518fce --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.moveTo.basic.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.path.moveTo.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.path.moveTo.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.moveTo.multiple.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.moveTo.multiple.html new file mode 100644 index 000000000..123d39314 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.moveTo.multiple.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.path.moveTo.multiple + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.path.moveTo.multiple

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.moveTo.newsubpath.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.moveTo.newsubpath.html new file mode 100644 index 000000000..caff9f81d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.moveTo.newsubpath.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.path.moveTo.newsubpath + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.path.moveTo.newsubpath

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.moveTo.nonfinite.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.moveTo.nonfinite.html new file mode 100644 index 000000000..c531f4d05 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.moveTo.nonfinite.html @@ -0,0 +1,40 @@ + + +Canvas test: 2d.path.moveTo.nonfinite + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.path.moveTo.nonfinite

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                moveTo() with Infinity/NaN is ignored

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.basic.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.basic.html new file mode 100644 index 000000000..247b68005 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.basic.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.path.quadraticCurveTo.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.path.quadraticCurveTo.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.ensuresubpath.1.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.ensuresubpath.1.html new file mode 100644 index 000000000..ac7bab212 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.ensuresubpath.1.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.path.quadraticCurveTo.ensuresubpath.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.path.quadraticCurveTo.ensuresubpath.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    If there is no subpath, the first control point is added (and nothing is drawn up to it)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.ensuresubpath.2.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.ensuresubpath.2.html new file mode 100644 index 000000000..95951a2ad --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.ensuresubpath.2.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.path.quadraticCurveTo.ensuresubpath.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.path.quadraticCurveTo.ensuresubpath.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      If there is no subpath, the first control point is added

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.nonfinite.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.nonfinite.html new file mode 100644 index 000000000..637d10954 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.nonfinite.html @@ -0,0 +1,57 @@ + + +Canvas test: 2d.path.quadraticCurveTo.nonfinite + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.path.quadraticCurveTo.nonfinite

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        quadraticCurveTo() with Infinity/NaN is ignored

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.scaled.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.scaled.html new file mode 100644 index 000000000..36801da94 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.scaled.html @@ -0,0 +1,40 @@ + + +Canvas test: 2d.path.quadraticCurveTo.scaled + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.path.quadraticCurveTo.scaled

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.shape.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.shape.html new file mode 100644 index 000000000..9311fc2a3 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.quadraticCurveTo.shape.html @@ -0,0 +1,39 @@ + + +Canvas test: 2d.path.quadraticCurveTo.shape + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.path.quadraticCurveTo.shape

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.basic.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.basic.html new file mode 100644 index 000000000..a5a6a733e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.basic.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.path.rect.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.path.rect.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.closed.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.closed.html new file mode 100644 index 000000000..98f06480d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.closed.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.rect.closed + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.path.rect.closed

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.end.1.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.end.1.html new file mode 100644 index 000000000..4cfe05817 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.end.1.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.rect.end.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.path.rect.end.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.end.2.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.end.2.html new file mode 100644 index 000000000..f961b9c52 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.end.2.html @@ -0,0 +1,39 @@ + + +Canvas test: 2d.path.rect.end.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.path.rect.end.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.negative.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.negative.html new file mode 100644 index 000000000..382623a5e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.negative.html @@ -0,0 +1,39 @@ + + +Canvas test: 2d.path.rect.negative + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.path.rect.negative

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.newsubpath.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.newsubpath.html new file mode 100644 index 000000000..e0e841b8c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.newsubpath.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.path.rect.newsubpath + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.path.rect.newsubpath

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.nonfinite.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.nonfinite.html new file mode 100644 index 000000000..173fd383f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.nonfinite.html @@ -0,0 +1,57 @@ + + +Canvas test: 2d.path.rect.nonfinite + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.path.rect.nonfinite

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          rect() with Infinity/NaN is ignored

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.selfintersect.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.selfintersect.html new file mode 100644 index 000000000..16be6232b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.selfintersect.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.rect.selfintersect + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.path.rect.selfintersect

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.winding.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.winding.html new file mode 100644 index 000000000..194e5733b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.winding.html @@ -0,0 +1,39 @@ + + +Canvas test: 2d.path.rect.winding + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.path.rect.winding

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.1.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.1.html new file mode 100644 index 000000000..dd4b1a456 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.1.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.rect.zero.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.path.rect.zero.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.2.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.2.html new file mode 100644 index 000000000..0bdfe380e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.2.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.rect.zero.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.path.rect.zero.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.3.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.3.html new file mode 100644 index 000000000..67dd2410b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.3.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.rect.zero.3 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.path.rect.zero.3

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.4.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.4.html new file mode 100644 index 000000000..a74399567 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.4.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.rect.zero.4 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.path.rect.zero.4

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.5.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.5.html new file mode 100644 index 000000000..81566fb7f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.5.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.path.rect.zero.5 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.path.rect.zero.5

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.6.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.6.html new file mode 100644 index 000000000..37b1c524c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.rect.zero.6.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.path.rect.zero.6 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.path.rect.zero.6

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.empty.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.empty.html new file mode 100644 index 000000000..671c4552b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.empty.html @@ -0,0 +1,40 @@ + + +Canvas test: 2d.path.stroke.empty + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.path.stroke.empty

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Empty subpaths are not stroked

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.overlap.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.overlap.html new file mode 100644 index 000000000..8a4d6989e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.overlap.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.path.stroke.overlap + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.path.stroke.overlap

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Stroked subpaths are combined before being drawn

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.overlap.png b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.overlap.png new file mode 100644 index 000000000..e2a35d48d Binary files /dev/null and b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.overlap.png differ diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.arc.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.arc.html new file mode 100644 index 000000000..fc4c23ffc --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.arc.html @@ -0,0 +1,45 @@ + + +Canvas test: 2d.path.stroke.prune.arc + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.path.stroke.prune.arc

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Zero-length line segments from arcTo and arc are removed before stroking

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.closed.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.closed.html new file mode 100644 index 000000000..d356c91fa --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.closed.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.path.stroke.prune.closed + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.path.stroke.prune.closed

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Zero-length line segments from closed paths are removed before stroking

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.corner.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.corner.html new file mode 100644 index 000000000..687777426 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.corner.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.path.stroke.prune.corner + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.path.stroke.prune.corner

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Zero-length line segments are removed before stroking with miters

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.curve.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.curve.html new file mode 100644 index 000000000..721cb6eb0 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.curve.html @@ -0,0 +1,45 @@ + + +Canvas test: 2d.path.stroke.prune.curve + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.path.stroke.prune.curve

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Zero-length line segments from quadraticCurveTo and bezierCurveTo are removed before stroking

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.line.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.line.html new file mode 100644 index 000000000..aa04d457e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.line.html @@ -0,0 +1,40 @@ + + +Canvas test: 2d.path.stroke.prune.line + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.path.stroke.prune.line

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Zero-length line segments from lineTo are removed before stroking

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.rect.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.rect.html new file mode 100644 index 000000000..45ead6db4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.prune.rect.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.path.stroke.prune.rect + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.path.stroke.prune.rect

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Zero-length line segments from rect and strokeRect are removed before stroking

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.scale1.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.scale1.html new file mode 100644 index 000000000..ae63be207 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.scale1.html @@ -0,0 +1,54 @@ + + +Canvas test: 2d.path.stroke.scale1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.path.stroke.scale1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Stroke line widths are scaled by the current transformation matrix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.scale2.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.scale2.html new file mode 100644 index 000000000..de8dd5e34 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.scale2.html @@ -0,0 +1,56 @@ + + +Canvas test: 2d.path.stroke.scale2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.path.stroke.scale2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Stroke line widths are scaled by the current transformation matrix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.skew.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.skew.html new file mode 100644 index 000000000..6c6e0a4d7 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.skew.html @@ -0,0 +1,70 @@ + + +Canvas test: 2d.path.stroke.skew + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.path.stroke.skew

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Strokes lines are skewed by the current transformation matrix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.unaffected.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.unaffected.html new file mode 100644 index 000000000..6980a0cfd --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.unaffected.html @@ -0,0 +1,42 @@ + + +Canvas test: 2d.path.stroke.unaffected + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.path.stroke.unaffected

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Stroking does not start a new path or subpath

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.union.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.union.html new file mode 100644 index 000000000..bf1f28a5b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.stroke.union.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.path.stroke.union + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.path.stroke.union

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Strokes in opposite directions are unioned, not subtracted

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.transformation.basic.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.transformation.basic.html new file mode 100644 index 000000000..528032153 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.transformation.basic.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.path.transformation.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.path.transformation.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.transformation.changing.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.transformation.changing.html new file mode 100644 index 000000000..24c32062d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.transformation.changing.html @@ -0,0 +1,42 @@ + + +Canvas test: 2d.path.transformation.changing + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.path.transformation.changing

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Transformations are applied while building paths, not when drawing

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/path-objects/2d.path.transformation.multiple.html b/testing/web-platform/tests/2dcontext/path-objects/2d.path.transformation.multiple.html new file mode 100644 index 000000000..5d78d28c9 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/path-objects/2d.path.transformation.multiple.html @@ -0,0 +1,47 @@ + + +Canvas test: 2d.path.transformation.multiple + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.path.transformation.multiple

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Transformations are applied while building paths, not when drawing

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/.gitkeep b/testing/web-platform/tests/2dcontext/pixel-manipulation/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create1.basic.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create1.basic.html new file mode 100644 index 000000000..cf236cd33 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create1.basic.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.imageData.create1.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.imageData.create1.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            createImageData(imgdata) exists and returns something

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create1.initial.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create1.initial.html new file mode 100644 index 000000000..15f67b72b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create1.initial.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.imageData.create1.initial + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.imageData.create1.initial

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              createImageData(imgdata) returns transparent black data of the right size

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create1.this.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create1.this.html new file mode 100644 index 000000000..1b9b2e095 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create1.this.html @@ -0,0 +1,30 @@ + + +Canvas test: 2d.imageData.create1.this + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.imageData.create1.this

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                createImageData(imgdata) should throw when called with the wrong |this|

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Defined in "Web IDL" (draft) +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create1.type.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create1.type.html new file mode 100644 index 000000000..888403550 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create1.type.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.imageData.create1.type + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.imageData.create1.type

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  createImageData(imgdata) returns an ImageData object containing a Uint8ClampedArray object

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create1.zero.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create1.zero.html new file mode 100644 index 000000000..928c430f8 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create1.zero.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.imageData.create1.zero + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.imageData.create1.zero

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    createImageData(null) throws TypeError

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.basic.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.basic.html new file mode 100644 index 000000000..51d3c13f9 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.basic.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.imageData.create2.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.imageData.create2.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      createImageData(sw, sh) exists and returns something

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.initial.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.initial.html new file mode 100644 index 000000000..a858c2437 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.initial.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.imageData.create2.initial + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.imageData.create2.initial

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        createImageData(sw, sh) returns transparent black data of the right size

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.large.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.large.html new file mode 100644 index 000000000..113a23194 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.large.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.imageData.create2.large + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.imageData.create2.large

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          createImageData(sw, sh) works for sizes much larger than the canvas

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.negative.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.negative.html new file mode 100644 index 000000000..7a06ed45c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.negative.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.imageData.create2.negative + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.imageData.create2.negative

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            createImageData(sw, sh) takes the absolute magnitude of the size arguments

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.nonfinite.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.nonfinite.html new file mode 100644 index 000000000..3dabc30a6 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.nonfinite.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.imageData.create2.nonfinite + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.imageData.create2.nonfinite

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              createImageData() throws TypeError if arguments are not finite

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Defined in "Web IDL" (draft) +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.round.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.round.html new file mode 100644 index 000000000..84c200178 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.round.html @@ -0,0 +1,30 @@ + + +Canvas test: 2d.imageData.create2.round + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.imageData.create2.round

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                createImageData(w, h) is rounded the same as getImageData(0, 0, w, h)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.this.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.this.html new file mode 100644 index 000000000..ff55218cf --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.this.html @@ -0,0 +1,29 @@ + + +Canvas test: 2d.imageData.create2.this + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.imageData.create2.this

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  createImageData(sw, sh) should throw when called with the wrong |this|

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Defined in "Web IDL" (draft) +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.tiny.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.tiny.html new file mode 100644 index 000000000..dac0e5e60 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.tiny.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.imageData.create2.tiny + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.imageData.create2.tiny

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    createImageData(sw, sh) works for sizes smaller than one pixel

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.type.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.type.html new file mode 100644 index 000000000..4e7b444cc --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.type.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.imageData.create2.type + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.imageData.create2.type

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      createImageData(sw, sh) returns an ImageData object containing a Uint8ClampedArray object

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.zero.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.zero.html new file mode 100644 index 000000000..c8957caac --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.create2.zero.html @@ -0,0 +1,29 @@ + + +Canvas test: 2d.imageData.create2.zero + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.imageData.create2.zero

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        createImageData(sw, sh) throws INDEX_SIZE_ERR if size is zero

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.basic.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.basic.html new file mode 100644 index 000000000..d8bad1fd5 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.basic.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.imageData.get.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.imageData.get.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          getImageData() exists and returns something

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.clamp.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.clamp.html new file mode 100644 index 000000000..cc235bac0 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.clamp.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.imageData.get.clamp + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.imageData.get.clamp

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            getImageData() clamps colours to the range [0, 255]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.length.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.length.html new file mode 100644 index 000000000..8bc30621c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.length.html @@ -0,0 +1,28 @@ + + +Canvas test: 2d.imageData.get.length + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.imageData.get.length

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              getImageData() returns a correctly-sized Uint8ClampedArray

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.nonfinite.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.nonfinite.html new file mode 100644 index 000000000..176b7d8bb --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.nonfinite.html @@ -0,0 +1,75 @@ + + +Canvas test: 2d.imageData.get.nonfinite + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.imageData.get.nonfinite

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                getImageData() throws TypeError if arguments are not finite

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Defined in "Web IDL" (draft) +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.nonpremul.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.nonpremul.html new file mode 100644 index 000000000..e8bce96f8 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.nonpremul.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.imageData.get.nonpremul + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.imageData.get.nonpremul

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  getImageData() returns non-premultiplied colours

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.order.alpha.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.order.alpha.html new file mode 100644 index 000000000..e2453c497 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.order.alpha.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.imageData.get.order.alpha + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.imageData.get.order.alpha

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    getImageData() returns A in the fourth component

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.order.cols.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.order.cols.html new file mode 100644 index 000000000..123831380 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.order.cols.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.imageData.get.order.cols + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.imageData.get.order.cols

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      getImageData() returns leftmost columns first

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.order.rgb.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.order.rgb.html new file mode 100644 index 000000000..37531ecfa --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.order.rgb.html @@ -0,0 +1,37 @@ + + +Canvas test: 2d.imageData.get.order.rgb + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.imageData.get.order.rgb

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        getImageData() returns R then G then B

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.order.rows.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.order.rows.html new file mode 100644 index 000000000..de77dc6dd --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.order.rows.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.imageData.get.order.rows + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.imageData.get.order.rows

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          getImageData() returns topmost rows first

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.range.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.range.html new file mode 100644 index 000000000..5f34e35df --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.range.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.imageData.get.range + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.imageData.get.range

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            getImageData() returns values in the range [0, 255]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.source.negative.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.source.negative.html new file mode 100644 index 000000000..4bab359fb --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.source.negative.html @@ -0,0 +1,46 @@ + + +Canvas test: 2d.imageData.get.source.negative + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.imageData.get.source.negative

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              getImageData() works with negative width and height, and returns top-to-bottom left-to-right

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.source.outside.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.source.outside.html new file mode 100644 index 000000000..9950b60ff --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.source.outside.html @@ -0,0 +1,86 @@ + + +Canvas test: 2d.imageData.get.source.outside + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.imageData.get.source.outside

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                getImageData() returns transparent black outside the canvas

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.source.size.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.source.size.html new file mode 100644 index 000000000..0782b1151 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.source.size.html @@ -0,0 +1,30 @@ + + +Canvas test: 2d.imageData.get.source.size + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.imageData.get.source.size

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  getImageData() returns bigger ImageData for bigger source rectangle

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.tiny.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.tiny.html new file mode 100644 index 000000000..982f3f28b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.tiny.html @@ -0,0 +1,30 @@ + + +Canvas test: 2d.imageData.get.tiny + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.imageData.get.tiny

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    getImageData() works for sizes smaller than one pixel

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.type.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.type.html new file mode 100644 index 000000000..76f711d58 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.type.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.imageData.get.type + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.imageData.get.type

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      getImageData() returns an ImageData object containing a Uint8ClampedArray object

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.unaffected.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.unaffected.html new file mode 100644 index 000000000..06afdb960 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.unaffected.html @@ -0,0 +1,42 @@ + + +Canvas test: 2d.imageData.get.unaffected + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.imageData.get.unaffected

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        getImageData() is not affected by context state

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.zero.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.zero.html new file mode 100644 index 000000000..ed1521723 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.get.zero.html @@ -0,0 +1,29 @@ + + +Canvas test: 2d.imageData.get.zero + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.imageData.get.zero

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          getImageData() throws INDEX_SIZE_ERR if size is zero

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.clamp.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.clamp.html new file mode 100644 index 000000000..61e10eea1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.clamp.html @@ -0,0 +1,55 @@ + + +Canvas test: 2d.imageData.object.clamp + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.imageData.object.clamp

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            ImageData.data clamps numbers to [0, 255]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.ctor.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.ctor.html new file mode 100644 index 000000000..c32596626 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.ctor.html @@ -0,0 +1,28 @@ + + +Canvas test: 2d.imageData.object.ctor + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.imageData.object.ctor

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              ImageData does not have a usable constructor

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.nan.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.nan.html new file mode 100644 index 000000000..4294b12f6 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.nan.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.imageData.object.nan + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.imageData.object.nan

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                ImageData.data converts NaN to 0

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.properties.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.properties.html new file mode 100644 index 000000000..a9ed94247 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.properties.html @@ -0,0 +1,30 @@ + + +Canvas test: 2d.imageData.object.properties + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.imageData.object.properties

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  ImageData objects have the right properties

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.readonly.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.readonly.html new file mode 100644 index 000000000..6f1833733 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.readonly.html @@ -0,0 +1,40 @@ + + +Canvas test: 2d.imageData.object.readonly + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.imageData.object.readonly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    ImageData objects properties are read-only

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.round.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.round.html new file mode 100644 index 000000000..7f50a92c6 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.round.html @@ -0,0 +1,55 @@ + + +Canvas test: 2d.imageData.object.round + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.imageData.object.round

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      ImageData.data rounds numbers with round-to-zero

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.set.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.set.html new file mode 100644 index 000000000..dd63ceb90 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.set.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.imageData.object.set + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.imageData.object.set

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        ImageData.data can be modified

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.string.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.string.html new file mode 100644 index 000000000..625b55750 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.string.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.imageData.object.string + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.imageData.object.string

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          ImageData.data converts strings to numbers with ToNumber

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.undefined.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.undefined.html new file mode 100644 index 000000000..1abf84330 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.object.undefined.html @@ -0,0 +1,30 @@ + + +Canvas test: 2d.imageData.object.undefined + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.imageData.object.undefined

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            ImageData.data converts undefined to 0

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.alpha.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.alpha.html new file mode 100644 index 000000000..9d1947149 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.alpha.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.imageData.put.alpha + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.imageData.put.alpha

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              putImageData() puts non-solid image data correctly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.alpha.png b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.alpha.png new file mode 100644 index 000000000..5428c6552 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.alpha.png differ diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.basic.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.basic.html new file mode 100644 index 000000000..7d7de3cc4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.basic.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.imageData.put.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.imageData.put.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                putImageData() puts image data from getImageData() onto the canvas

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.clip.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.clip.html new file mode 100644 index 000000000..8e8b19a60 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.clip.html @@ -0,0 +1,37 @@ + + +Canvas test: 2d.imageData.put.clip + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.imageData.put.clip

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  putImageData() is not affected by clipping regions

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.created.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.created.html new file mode 100644 index 000000000..4b1dd11bd --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.created.html @@ -0,0 +1,37 @@ + + +Canvas test: 2d.imageData.put.created + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.imageData.put.created

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    putImageData() puts image data from createImageData() onto the canvas

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.cross.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.cross.html new file mode 100644 index 000000000..5fc59090a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.cross.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.imageData.put.cross + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.imageData.put.cross

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      putImageData() accepts image data got from a different canvas

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.dirty.negative.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.dirty.negative.html new file mode 100644 index 000000000..67cf410cc --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.dirty.negative.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.imageData.put.dirty.negative + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.imageData.put.dirty.negative

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        putImageData() handles negative-sized dirty rectangles correctly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.dirty.outside.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.dirty.outside.html new file mode 100644 index 000000000..81dc98ca9 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.dirty.outside.html @@ -0,0 +1,46 @@ + + +Canvas test: 2d.imageData.put.dirty.outside + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.imageData.put.dirty.outside

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          putImageData() handles dirty rectangles outside the canvas correctly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.dirty.rect1.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.dirty.rect1.html new file mode 100644 index 000000000..b94a9f581 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.dirty.rect1.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.imageData.put.dirty.rect1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.imageData.put.dirty.rect1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            putImageData() only modifies areas inside the dirty rectangle, using width and height

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.dirty.rect2.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.dirty.rect2.html new file mode 100644 index 000000000..1fb5c1416 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.dirty.rect2.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.imageData.put.dirty.rect2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.imageData.put.dirty.rect2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              putImageData() only modifies areas inside the dirty rectangle, using x and y

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.dirty.zero.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.dirty.zero.html new file mode 100644 index 000000000..726fdb809 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.dirty.zero.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.imageData.put.dirty.zero + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.imageData.put.dirty.zero

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                putImageData() with zero-sized dirty rectangle puts nothing

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.modified.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.modified.html new file mode 100644 index 000000000..5815aeb26 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.modified.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.imageData.put.modified + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.imageData.put.modified

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  putImageData() puts modified image data correctly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.nonfinite.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.nonfinite.html new file mode 100644 index 000000000..861545ff3 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.nonfinite.html @@ -0,0 +1,109 @@ + + +Canvas test: 2d.imageData.put.nonfinite + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.imageData.put.nonfinite

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    putImageData() throws TypeError if arguments are not finite

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Defined in "Web IDL" (draft) +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.null.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.null.html new file mode 100644 index 000000000..f827babc5 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.null.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.imageData.put.null + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.imageData.put.null

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      putImageData() with null imagedata throws TypeError

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.path.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.path.html new file mode 100644 index 000000000..7994e8647 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.path.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.imageData.put.path + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.imageData.put.path

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        putImageData() does not affect the current path

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.unaffected.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.unaffected.html new file mode 100644 index 000000000..8eee15995 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.unaffected.html @@ -0,0 +1,39 @@ + + +Canvas test: 2d.imageData.put.unaffected + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.imageData.put.unaffected

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          putImageData() is not affected by context state

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.unchanged.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.unchanged.html new file mode 100644 index 000000000..59e05fbce --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.unchanged.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.imageData.put.unchanged + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.imageData.put.unchanged

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            putImageData(getImageData(...), ...) has no effect

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.wrongtype.html b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.wrongtype.html new file mode 100644 index 000000000..085097fd4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/pixel-manipulation/2d.imageData.put.wrongtype.html @@ -0,0 +1,30 @@ + + +Canvas test: 2d.imageData.put.wrongtype + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.imageData.put.wrongtype

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              putImageData() does not accept non-ImageData objects

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/shadows/.gitkeep b/testing/web-platform/tests/2dcontext/shadows/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.1.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.1.html new file mode 100644 index 000000000..d541cd4b8 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.1.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.shadow.alpha.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.shadow.alpha.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Shadow colour alpha components are used

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.2.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.2.html new file mode 100644 index 000000000..217618292 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.2.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.shadow.alpha.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.shadow.alpha.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Shadow colour alpha components are used

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.2.png b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.2.png new file mode 100644 index 000000000..8764e89b3 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.2.png differ diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.3.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.3.html new file mode 100644 index 000000000..970575478 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.3.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.shadow.alpha.3 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.shadow.alpha.3

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Shadows are affected by globalAlpha

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.3.png b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.3.png new file mode 100644 index 000000000..8764e89b3 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.3.png differ diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.4.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.4.html new file mode 100644 index 000000000..0621af631 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.4.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.shadow.alpha.4 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.shadow.alpha.4

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Shadows with alpha components are correctly affected by globalAlpha

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.4.png b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.4.png new file mode 100644 index 000000000..8764e89b3 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.4.png differ diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.5.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.5.html new file mode 100644 index 000000000..95cb2f399 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.5.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.shadow.alpha.5 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.shadow.alpha.5

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Shadows of shapes with alpha components are drawn correctly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.5.png b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.5.png new file mode 100644 index 000000000..8764e89b3 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.alpha.5.png differ diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowBlur.initial.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowBlur.initial.html new file mode 100644 index 000000000..7b65cac6f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowBlur.initial.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.shadow.attributes.shadowBlur.initial + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.shadow.attributes.shadowBlur.initial

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowBlur.invalid.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowBlur.invalid.html new file mode 100644 index 000000000..c4bf2ba99 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowBlur.invalid.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.shadow.attributes.shadowBlur.invalid + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.shadow.attributes.shadowBlur.invalid

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowBlur.valid.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowBlur.valid.html new file mode 100644 index 000000000..6aa9f9b1a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowBlur.valid.html @@ -0,0 +1,37 @@ + + +Canvas test: 2d.shadow.attributes.shadowBlur.valid + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.shadow.attributes.shadowBlur.valid

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowColor.initial.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowColor.initial.html new file mode 100644 index 000000000..3f7471333 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowColor.initial.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.shadow.attributes.shadowColor.initial + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.shadow.attributes.shadowColor.initial

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowColor.invalid.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowColor.invalid.html new file mode 100644 index 000000000..5f28ecbae --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowColor.invalid.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.shadow.attributes.shadowColor.invalid + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.shadow.attributes.shadowColor.invalid

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowColor.valid.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowColor.valid.html new file mode 100644 index 000000000..02ce65c90 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowColor.valid.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.shadow.attributes.shadowColor.valid + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.shadow.attributes.shadowColor.valid

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowOffset.initial.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowOffset.initial.html new file mode 100644 index 000000000..35f1317f2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowOffset.initial.html @@ -0,0 +1,28 @@ + + +Canvas test: 2d.shadow.attributes.shadowOffset.initial + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.shadow.attributes.shadowOffset.initial

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowOffset.invalid.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowOffset.invalid.html new file mode 100644 index 000000000..0b1ef728c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowOffset.invalid.html @@ -0,0 +1,46 @@ + + +Canvas test: 2d.shadow.attributes.shadowOffset.invalid + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.shadow.attributes.shadowOffset.invalid

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowOffset.valid.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowOffset.valid.html new file mode 100644 index 000000000..4133ebb94 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.attributes.shadowOffset.valid.html @@ -0,0 +1,50 @@ + + +Canvas test: 2d.shadow.attributes.shadowOffset.valid + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.shadow.attributes.shadowOffset.valid

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.blur.high-manual.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.blur.high-manual.html new file mode 100644 index 000000000..957f5b802 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.blur.high-manual.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.shadow.blur.high + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.shadow.blur.high

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Shadows look correct for large blurs

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.blur.high.png b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.blur.high.png new file mode 100644 index 000000000..743640b79 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.blur.high.png differ diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.blur.low-manual.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.blur.low-manual.html new file mode 100644 index 000000000..548db5c5e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.blur.low-manual.html @@ -0,0 +1,39 @@ + + +Canvas test: 2d.shadow.blur.low + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.shadow.blur.low

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Shadows look correct for small blurs

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.blur.low.png b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.blur.low.png new file mode 100644 index 000000000..e1922ae79 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.blur.low.png differ diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.canvas.alpha.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.canvas.alpha.html new file mode 100644 index 000000000..584703dff --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.canvas.alpha.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.shadow.canvas.alpha + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.shadow.canvas.alpha

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Shadows are drawn correctly for partially-transparent canvases

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.canvas.alpha.png b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.canvas.alpha.png new file mode 100644 index 000000000..8764e89b3 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.canvas.alpha.png differ diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.canvas.basic.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.canvas.basic.html new file mode 100644 index 000000000..824c66894 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.canvas.basic.html @@ -0,0 +1,40 @@ + + +Canvas test: 2d.shadow.canvas.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.shadow.canvas.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Shadows are drawn for canvases

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.canvas.transparent.1.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.canvas.transparent.1.html new file mode 100644 index 000000000..13ddd33e1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.canvas.transparent.1.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.shadow.canvas.transparent.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.shadow.canvas.transparent.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Shadows are not drawn for transparent canvases

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.canvas.transparent.2.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.canvas.transparent.2.html new file mode 100644 index 000000000..e795fa1e2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.canvas.transparent.2.html @@ -0,0 +1,46 @@ + + +Canvas test: 2d.shadow.canvas.transparent.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.shadow.canvas.transparent.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Shadows are not drawn for transparent parts of canvases

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.clip.1.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.clip.1.html new file mode 100644 index 000000000..50fbb8711 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.clip.1.html @@ -0,0 +1,42 @@ + + +Canvas test: 2d.shadow.clip.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.shadow.clip.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Shadows of clipped shapes are still drawn within the clipping region

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.clip.2.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.clip.2.html new file mode 100644 index 000000000..239b43b98 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.clip.2.html @@ -0,0 +1,42 @@ + + +Canvas test: 2d.shadow.clip.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.shadow.clip.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Shadows are not drawn outside the clipping region

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.clip.3.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.clip.3.html new file mode 100644 index 000000000..6b1bb02fc --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.clip.3.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.shadow.clip.3 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.shadow.clip.3

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Shadows of clipped shapes are still drawn within the clipping region

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.composite.1.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.composite.1.html new file mode 100644 index 000000000..e27c1e2c0 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.composite.1.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.shadow.composite.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.shadow.composite.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Shadows are drawn using globalCompositeOperation

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.composite.2.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.composite.2.html new file mode 100644 index 000000000..960b44b54 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.composite.2.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.shadow.composite.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.shadow.composite.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Shadows are drawn using globalCompositeOperation

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.composite.3.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.composite.3.html new file mode 100644 index 000000000..feee1ce5e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.composite.3.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.shadow.composite.3 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.shadow.composite.3

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Areas outside shadows are drawn correctly with destination-out

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.enable.blur.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.enable.blur.html new file mode 100644 index 000000000..f94f5f69f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.enable.blur.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.shadow.enable.blur + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.shadow.enable.blur

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Shadows are drawn if shadowBlur is set

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.enable.off.1.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.enable.off.1.html new file mode 100644 index 000000000..161ec52c4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.enable.off.1.html @@ -0,0 +1,30 @@ + + +Canvas test: 2d.shadow.enable.off.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.shadow.enable.off.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Shadows are not drawn when only shadowColor is set

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.enable.off.2.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.enable.off.2.html new file mode 100644 index 000000000..23bfa752a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.enable.off.2.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.shadow.enable.off.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.shadow.enable.off.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Shadows are not drawn when only shadowColor is set

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.enable.x.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.enable.x.html new file mode 100644 index 000000000..b90da98df --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.enable.x.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.shadow.enable.x + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.shadow.enable.x

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Shadows are drawn if shadowOffsetX is set

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.enable.y.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.enable.y.html new file mode 100644 index 000000000..32750e6f8 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.enable.y.html @@ -0,0 +1,32 @@ + + +Canvas test: 2d.shadow.enable.y + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.shadow.enable.y

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Shadows are drawn if shadowOffsetY is set

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.gradient.alpha.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.gradient.alpha.html new file mode 100644 index 000000000..31c4adc50 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.gradient.alpha.html @@ -0,0 +1,37 @@ + + +Canvas test: 2d.shadow.gradient.alpha + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.shadow.gradient.alpha

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Shadows are drawn correctly for partially-transparent gradient fills

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.gradient.alpha.png b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.gradient.alpha.png new file mode 100644 index 000000000..8764e89b3 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.gradient.alpha.png differ diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.gradient.basic.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.gradient.basic.html new file mode 100644 index 000000000..cdb223232 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.gradient.basic.html @@ -0,0 +1,37 @@ + + +Canvas test: 2d.shadow.gradient.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.shadow.gradient.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Shadows are drawn for gradient fills

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.gradient.transparent.1.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.gradient.transparent.1.html new file mode 100644 index 000000000..d4a21c6b3 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.gradient.transparent.1.html @@ -0,0 +1,37 @@ + + +Canvas test: 2d.shadow.gradient.transparent.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.shadow.gradient.transparent.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Shadows are not drawn for transparent gradient fills

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.gradient.transparent.2.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.gradient.transparent.2.html new file mode 100644 index 000000000..be5d93a5b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.gradient.transparent.2.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.shadow.gradient.transparent.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.shadow.gradient.transparent.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Shadows are not drawn for transparent parts of gradient fills

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.alpha.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.alpha.html new file mode 100644 index 000000000..9e7a56973 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.alpha.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.shadow.image.alpha + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.shadow.image.alpha

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Shadows are drawn correctly for partially-transparent images

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.alpha.png b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.alpha.png new file mode 100644 index 000000000..8764e89b3 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.alpha.png differ diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.basic.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.basic.html new file mode 100644 index 000000000..570451ae9 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.basic.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.shadow.image.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.shadow.image.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Shadows are drawn for images

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.scale.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.scale.html new file mode 100644 index 000000000..ded6fc0d6 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.scale.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.shadow.image.scale + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.shadow.image.scale

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Shadows are drawn correctly for scaled images

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.section.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.section.html new file mode 100644 index 000000000..9dc9bca67 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.section.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.shadow.image.section + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.shadow.image.section

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Shadows are not drawn for areas outside image source rectangles

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.transparent.1.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.transparent.1.html new file mode 100644 index 000000000..13dff1f2d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.transparent.1.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.shadow.image.transparent.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.shadow.image.transparent.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Shadows are not drawn for transparent images

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.transparent.2.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.transparent.2.html new file mode 100644 index 000000000..17a26407d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.image.transparent.2.html @@ -0,0 +1,40 @@ + + +Canvas test: 2d.shadow.image.transparent.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.shadow.image.transparent.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Shadows are not drawn for transparent parts of images

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.offset.negativeX.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.offset.negativeX.html new file mode 100644 index 000000000..da1c39ba0 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.offset.negativeX.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.shadow.offset.negativeX + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.shadow.offset.negativeX

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Shadows can be offset with negative x

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.offset.negativeY.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.offset.negativeY.html new file mode 100644 index 000000000..0f7a7f0ad --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.offset.negativeY.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.shadow.offset.negativeY + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.shadow.offset.negativeY

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Shadows can be offset with negative y

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.offset.positiveX.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.offset.positiveX.html new file mode 100644 index 000000000..969d9b43a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.offset.positiveX.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.shadow.offset.positiveX + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.shadow.offset.positiveX

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Shadows can be offset with positive x

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.offset.positiveY.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.offset.positiveY.html new file mode 100644 index 000000000..c797d709f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.offset.positiveY.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.shadow.offset.positiveY + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.shadow.offset.positiveY

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Shadows can be offset with positive y

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.outside.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.outside.html new file mode 100644 index 000000000..ef3492226 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.outside.html @@ -0,0 +1,42 @@ + + +Canvas test: 2d.shadow.outside + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.shadow.outside

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Shadows of shapes outside the visible area can be offset onto the visible area

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.pattern.alpha.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.pattern.alpha.html new file mode 100644 index 000000000..5fcfcc4b0 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.pattern.alpha.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.shadow.pattern.alpha + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.shadow.pattern.alpha

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Shadows are drawn correctly for partially-transparent fill patterns

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.pattern.alpha.png b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.pattern.alpha.png new file mode 100644 index 000000000..8764e89b3 Binary files /dev/null and b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.pattern.alpha.png differ diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.pattern.basic.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.pattern.basic.html new file mode 100644 index 000000000..38b9a7367 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.pattern.basic.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.shadow.pattern.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.shadow.pattern.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Shadows are drawn for fill patterns

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.pattern.transparent.1.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.pattern.transparent.1.html new file mode 100644 index 000000000..fcdda5a20 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.pattern.transparent.1.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.shadow.pattern.transparent.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.shadow.pattern.transparent.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Shadows are not drawn for transparent fill patterns

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.pattern.transparent.2.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.pattern.transparent.2.html new file mode 100644 index 000000000..3dbb856bf --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.pattern.transparent.2.html @@ -0,0 +1,40 @@ + + +Canvas test: 2d.shadow.pattern.transparent.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.shadow.pattern.transparent.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Shadows are not drawn for transparent parts of fill patterns

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.basic.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.basic.html new file mode 100644 index 000000000..4e5bd06b2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.basic.html @@ -0,0 +1,40 @@ + + +Canvas test: 2d.shadow.stroke.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.shadow.stroke.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Shadows are drawn for strokes

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.cap.1.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.cap.1.html new file mode 100644 index 000000000..04450b979 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.cap.1.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.shadow.stroke.cap.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.shadow.stroke.cap.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Shadows are not drawn for areas outside stroke caps

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.cap.2.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.cap.2.html new file mode 100644 index 000000000..11a7cf3cf --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.cap.2.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.shadow.stroke.cap.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.shadow.stroke.cap.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Shadows are drawn for stroke caps

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.join.1.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.join.1.html new file mode 100644 index 000000000..d204874d7 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.join.1.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.shadow.stroke.join.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.shadow.stroke.join.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Shadows are not drawn for areas outside stroke joins

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.join.2.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.join.2.html new file mode 100644 index 000000000..ccff894fd --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.join.2.html @@ -0,0 +1,45 @@ + + +Canvas test: 2d.shadow.stroke.join.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.shadow.stroke.join.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Shadows are drawn for stroke joins

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.join.3.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.join.3.html new file mode 100644 index 000000000..25044ebfc --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.stroke.join.3.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.shadow.stroke.join.3 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.shadow.stroke.join.3

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Shadows are drawn for stroke joins respecting miter limit

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.transform.1.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.transform.1.html new file mode 100644 index 000000000..03a4ab2e4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.transform.1.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.shadow.transform.1 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.shadow.transform.1

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Shadows take account of transformations

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/shadows/2d.shadow.transform.2.html b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.transform.2.html new file mode 100644 index 000000000..8e1ac095b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/2d.shadow.transform.2.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.shadow.transform.2 + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.shadow.transform.2

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Shadow offsets are not affected by transformations

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/shadows/canvas_shadows_001.htm b/testing/web-platform/tests/2dcontext/shadows/canvas_shadows_001.htm new file mode 100644 index 000000000..1763950d6 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/canvas_shadows_001.htm @@ -0,0 +1,60 @@ + + + + HTML5 Canvas Test: Shadows for linear gradients + + + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Description: Shadows must be drawn for linear gradients.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Test passes if there is one gradient filled rectangle and one black rectangle, and no red seen on the page.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + Browser does not support HTML5 Canvas. + + diff --git a/testing/web-platform/tests/2dcontext/shadows/canvas_shadows_002-ref.htm b/testing/web-platform/tests/2dcontext/shadows/canvas_shadows_002-ref.htm new file mode 100644 index 000000000..0658be808 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/canvas_shadows_002-ref.htm @@ -0,0 +1,27 @@ + + + + HTML5 Canvas Test: Shadows for images + + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Description: Shadows must be drawn for images.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Test passes if two black rectangles are shown and there is no red visible on the page.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + Browser does not support HTML5 Canvas. + + + diff --git a/testing/web-platform/tests/2dcontext/shadows/canvas_shadows_002.htm b/testing/web-platform/tests/2dcontext/shadows/canvas_shadows_002.htm new file mode 100644 index 000000000..908fffea1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/shadows/canvas_shadows_002.htm @@ -0,0 +1,34 @@ + + + + HTML5 Canvas Test: Shadows for images + + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Description: Shadows must be drawn for images.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Test passes if two black rectangles are shown and there is no red visible on the page.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + Browser does not support HTML5 Canvas. + + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/.gitkeep b/testing/web-platform/tests/2dcontext/text-styles/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.align.default.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.align.default.html new file mode 100644 index 000000000..6c3b5016a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.align.default.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.text.align.default + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.text.align.default

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.align.invalid.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.align.invalid.html new file mode 100644 index 000000000..36d3aaaf4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.align.invalid.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.text.align.invalid + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.text.align.invalid

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.align.valid.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.align.valid.html new file mode 100644 index 000000000..667f1bb0b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.align.valid.html @@ -0,0 +1,40 @@ + + +Canvas test: 2d.text.align.valid + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.text.align.valid

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.baseline.default.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.baseline.default.html new file mode 100644 index 000000000..b19bcc37e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.baseline.default.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.text.baseline.default + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.text.baseline.default

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.baseline.invalid.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.baseline.invalid.html new file mode 100644 index 000000000..4cba62a14 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.baseline.invalid.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.text.baseline.invalid + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.text.baseline.invalid

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.baseline.valid.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.baseline.valid.html new file mode 100644 index 000000000..e2a37b4ed --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.baseline.valid.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.text.baseline.valid + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.text.baseline.valid

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.baseline.bottom.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.baseline.bottom.html new file mode 100644 index 000000000..cde7e891d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.baseline.bottom.html @@ -0,0 +1,48 @@ + + +Canvas test: 2d.text.draw.baseline.bottom + + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.text.draw.baseline.bottom

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                textBaseline bottom is the bottom of the em square (not the bounding box)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +A +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.baseline.hanging.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.baseline.hanging.html new file mode 100644 index 000000000..e5bdb98cc --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.baseline.hanging.html @@ -0,0 +1,48 @@ + + +Canvas test: 2d.text.draw.baseline.hanging + + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.text.draw.baseline.hanging

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +A +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.baseline.ideographic.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.baseline.ideographic.html new file mode 100644 index 000000000..cc99e1ab4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.baseline.ideographic.html @@ -0,0 +1,48 @@ + + +Canvas test: 2d.text.draw.baseline.ideographic + + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.text.draw.baseline.ideographic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +A +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.baseline.middle.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.baseline.middle.html new file mode 100644 index 000000000..6cdbb17e6 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.baseline.middle.html @@ -0,0 +1,48 @@ + + +Canvas test: 2d.text.draw.baseline.middle + + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.text.draw.baseline.middle

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      textBaseline middle is the middle of the em square (not the bounding box)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +A +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.baseline.top.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.baseline.top.html new file mode 100644 index 000000000..15c0c1f38 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.baseline.top.html @@ -0,0 +1,48 @@ + + +Canvas test: 2d.text.draw.baseline.top + + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.text.draw.baseline.top

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        textBaseline top is the top of the em square (not the bounding box)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +A +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.space.collapse.end.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.space.collapse.end.html new file mode 100644 index 000000000..9ce607000 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.space.collapse.end.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.text.draw.space.collapse.end + + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.text.draw.space.collapse.end

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Space characters at the end of a line are collapsed (per CSS)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +A +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.space.collapse.other.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.space.collapse.other.html new file mode 100644 index 000000000..25275b5b5 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.space.collapse.other.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.text.draw.space.collapse.other + + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.text.draw.space.collapse.other

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Space characters are converted to U+0020, and collapsed (per CSS)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +A +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.space.collapse.space.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.space.collapse.space.html new file mode 100644 index 000000000..3069e7946 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.space.collapse.space.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.text.draw.space.collapse.space + + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.text.draw.space.collapse.space

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Space characters are converted to U+0020, and collapsed (per CSS)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +A +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.space.collapse.start.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.space.collapse.start.html new file mode 100644 index 000000000..b3b05f436 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.draw.space.collapse.start.html @@ -0,0 +1,43 @@ + + +Canvas test: 2d.text.draw.space.collapse.start + + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.text.draw.space.collapse.start

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Space characters at the start of a line are collapsed (per CSS)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +A +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.font.default.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.font.default.html new file mode 100644 index 000000000..e7405e350 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.font.default.html @@ -0,0 +1,27 @@ + + +Canvas test: 2d.text.font.default + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.text.font.default

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.basic.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.basic.html new file mode 100644 index 000000000..b4ae41cbc --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.basic.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.text.font.parse.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.text.font.parse.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.complex.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.complex.html new file mode 100644 index 000000000..51917f361 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.complex.html @@ -0,0 +1,28 @@ + + +Canvas test: 2d.text.font.parse.complex + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.text.font.parse.complex

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.invalid.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.invalid.html new file mode 100644 index 000000000..f65d680b0 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.invalid.html @@ -0,0 +1,56 @@ + + +Canvas test: 2d.text.font.parse.invalid + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.text.font.parse.invalid

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.size.percentage.default.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.size.percentage.default.html new file mode 100644 index 000000000..21eebde0f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.size.percentage.default.html @@ -0,0 +1,30 @@ + + +Canvas test: 2d.text.font.parse.size.percentage.default + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.text.font.parse.size.percentage.default

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.size.percentage.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.size.percentage.html new file mode 100644 index 000000000..6a05e48cf --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.size.percentage.html @@ -0,0 +1,30 @@ + + +Canvas test: 2d.text.font.parse.size.percentage + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.text.font.parse.size.percentage

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.system.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.system.html new file mode 100644 index 000000000..bc86f5c15 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.font.parse.system.html @@ -0,0 +1,28 @@ + + +Canvas test: 2d.text.font.parse.system + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.text.font.parse.system

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              System fonts must be computed to explicit values

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/2d.text.measure.width.space.html b/testing/web-platform/tests/2dcontext/text-styles/2d.text.measure.width.space.html new file mode 100644 index 000000000..dfa1dee1c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/2d.text.measure.width.space.html @@ -0,0 +1,44 @@ + + +Canvas test: 2d.text.measure.width.space + + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.text.measure.width.space

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Space characters are converted to U+0020 and collapsed (per CSS)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +A +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/canvas_text_font_001-ref.htm b/testing/web-platform/tests/2dcontext/text-styles/canvas_text_font_001-ref.htm new file mode 100644 index 000000000..1a19757e0 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/canvas_text_font_001-ref.htm @@ -0,0 +1,22 @@ + + + + HTML5 Canvas Test: Ignore property-independent style sheet syntax "inherit" in Text (reference) + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Description: Ignore "inherit" property-independent style sheet syntax without assigning a new font value.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Test passes if there are two identical black boxes below.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + Browser does not support HTML5 Canvas. + + diff --git a/testing/web-platform/tests/2dcontext/text-styles/canvas_text_font_001.htm b/testing/web-platform/tests/2dcontext/text-styles/canvas_text_font_001.htm new file mode 100644 index 000000000..923ce71c0 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/text-styles/canvas_text_font_001.htm @@ -0,0 +1,33 @@ + + + + HTML5 Canvas Test: Ignore property-independent style sheet syntax "inherit" in Text + + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Description: Ignore "inherit" property-independent style sheet syntax without assigning a new font value.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Test passes if there are two identical black boxes below.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + Browser does not support HTML5 Canvas. + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/.gitkeep b/testing/web-platform/tests/2dcontext/the-canvas-state/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.bitmap.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.bitmap.html new file mode 100644 index 000000000..d22720c09 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.bitmap.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.state.saverestore.bitmap + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.state.saverestore.bitmap

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  save()/restore() does not affect the current bitmap

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.clip.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.clip.html new file mode 100644 index 000000000..5f4d1ad35 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.clip.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.state.saverestore.clip + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.state.saverestore.clip

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    save()/restore() affects the clipping path

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.fillStyle.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.fillStyle.html new file mode 100644 index 000000000..a44f4f96a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.fillStyle.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.state.saverestore.fillStyle + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.state.saverestore.fillStyle

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      save()/restore() works for fillStyle

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.font.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.font.html new file mode 100644 index 000000000..287400646 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.font.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.state.saverestore.font + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.state.saverestore.font

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        save()/restore() works for font

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.globalAlpha.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.globalAlpha.html new file mode 100644 index 000000000..27fc1aed8 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.globalAlpha.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.state.saverestore.globalAlpha + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.state.saverestore.globalAlpha

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          save()/restore() works for globalAlpha

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.globalCompositeOperation.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.globalCompositeOperation.html new file mode 100644 index 000000000..419a96052 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.globalCompositeOperation.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.state.saverestore.globalCompositeOperation + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.state.saverestore.globalCompositeOperation

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            save()/restore() works for globalCompositeOperation

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.imageSmoothingEnabled.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.imageSmoothingEnabled.html new file mode 100644 index 000000000..e99be83d5 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.imageSmoothingEnabled.html @@ -0,0 +1,47 @@ + + +CanvasRenderingContext2D imageSmoothingEnabled save/restore test + + + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.lineCap.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.lineCap.html new file mode 100644 index 000000000..cb750219f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.lineCap.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.state.saverestore.lineCap + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.state.saverestore.lineCap

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              save()/restore() works for lineCap

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.lineJoin.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.lineJoin.html new file mode 100644 index 000000000..ff1411265 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.lineJoin.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.state.saverestore.lineJoin + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.state.saverestore.lineJoin

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                save()/restore() works for lineJoin

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.lineWidth.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.lineWidth.html new file mode 100644 index 000000000..21bb26673 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.lineWidth.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.state.saverestore.lineWidth + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.state.saverestore.lineWidth

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  save()/restore() works for lineWidth

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.miterLimit.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.miterLimit.html new file mode 100644 index 000000000..f49edced1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.miterLimit.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.state.saverestore.miterLimit + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.state.saverestore.miterLimit

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    save()/restore() works for miterLimit

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.path.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.path.html new file mode 100644 index 000000000..b6f269c32 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.path.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.state.saverestore.path + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.state.saverestore.path

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      save()/restore() does not affect the current path

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.shadowBlur.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.shadowBlur.html new file mode 100644 index 000000000..7f1ce6f9b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.shadowBlur.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.state.saverestore.shadowBlur + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.state.saverestore.shadowBlur

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        save()/restore() works for shadowBlur

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.shadowColor.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.shadowColor.html new file mode 100644 index 000000000..95c36dfad --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.shadowColor.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.state.saverestore.shadowColor + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.state.saverestore.shadowColor

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          save()/restore() works for shadowColor

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.shadowOffsetX.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.shadowOffsetX.html new file mode 100644 index 000000000..363d5cc24 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.shadowOffsetX.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.state.saverestore.shadowOffsetX + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.state.saverestore.shadowOffsetX

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            save()/restore() works for shadowOffsetX

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.shadowOffsetY.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.shadowOffsetY.html new file mode 100644 index 000000000..5edb62a7a --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.shadowOffsetY.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.state.saverestore.shadowOffsetY + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.state.saverestore.shadowOffsetY

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              save()/restore() works for shadowOffsetY

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.stack.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.stack.html new file mode 100644 index 000000000..3a5dbea10 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.stack.html @@ -0,0 +1,36 @@ + + +Canvas test: 2d.state.saverestore.stack + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.state.saverestore.stack

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                save()/restore() can be nested as a stack

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.stackdepth.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.stackdepth.html new file mode 100644 index 000000000..5e6c459f3 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.stackdepth.html @@ -0,0 +1,37 @@ + + +Canvas test: 2d.state.saverestore.stackdepth + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.state.saverestore.stackdepth

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  save()/restore() stack depth is not unreasonably limited

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.strokeStyle.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.strokeStyle.html new file mode 100644 index 000000000..53a28f555 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.strokeStyle.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.state.saverestore.strokeStyle + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.state.saverestore.strokeStyle

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    save()/restore() works for strokeStyle

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.textAlign.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.textAlign.html new file mode 100644 index 000000000..ea1b3f2e2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.textAlign.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.state.saverestore.textAlign + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.state.saverestore.textAlign

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      save()/restore() works for textAlign

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.textBaseline.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.textBaseline.html new file mode 100644 index 000000000..22664ef1d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.textBaseline.html @@ -0,0 +1,41 @@ + + +Canvas test: 2d.state.saverestore.textBaseline + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.state.saverestore.textBaseline

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        save()/restore() works for textBaseline

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.transformation.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.transformation.html new file mode 100644 index 000000000..744f7ab7f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.transformation.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.state.saverestore.transformation + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.state.saverestore.transformation

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          save()/restore() affects the current transformation matrix

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.underflow.html b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.underflow.html new file mode 100644 index 000000000..c965b0256 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/2d.state.saverestore.underflow.html @@ -0,0 +1,31 @@ + + +Canvas test: 2d.state.saverestore.underflow + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.state.saverestore.underflow

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            restore() with an empty stack has no effect

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/canvas_state_restore_001-ref.htm b/testing/web-platform/tests/2dcontext/the-canvas-state/canvas_state_restore_001-ref.htm new file mode 100644 index 000000000..aee610d2e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/canvas_state_restore_001-ref.htm @@ -0,0 +1,11 @@ + + + + HTML5 Canvas Test: restore() pops top entry in drawing state stack + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Description: restore() pops the top entry in the drawing state stack.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              3 colors
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/the-canvas-state/canvas_state_restore_001.htm b/testing/web-platform/tests/2dcontext/the-canvas-state/canvas_state_restore_001.htm new file mode 100644 index 000000000..6d5a3cb20 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/the-canvas-state/canvas_state_restore_001.htm @@ -0,0 +1,42 @@ + + + + HTML5 Canvas Test: restore() pops top entry in drawing state stack + + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Description: restore() pops the top entry in the drawing state stack.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + Browser does not support HTML5 Canvas. + + diff --git a/testing/web-platform/tests/2dcontext/tools/LICENSE.txt b/testing/web-platform/tests/2dcontext/tools/LICENSE.txt new file mode 100644 index 000000000..b248aa87e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/tools/LICENSE.txt @@ -0,0 +1,36 @@ +2DContext and test suite + +Copyright (c) 2010 Philip Taylor + +The code and all associated data files may be used under the terms of the +following license: + + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +* Redistributions of works must retain the original copyright notice, this + list of conditions and the following disclaimer. + +* Redistributions in binary form must reproduce the original copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + +* Neither the name of the W3C nor the names of its contributors may be used to + endorse or promote products derived from this work without specific prior + written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + +Alternatively, the code and data may be used under the terms of +http://www.w3.org/Consortium/Legal/2008/04-testsuite-license.html diff --git a/testing/web-platform/tests/2dcontext/tools/current-work-canvas.xhtml b/testing/web-platform/tests/2dcontext/tools/current-work-canvas.xhtml new file mode 100644 index 000000000..b41ad7d4d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/tools/current-work-canvas.xhtml @@ -0,0 +1,3693 @@ +HTML Standard

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4.8.11 The canvas element

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Categories
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Flow content.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Phrasing content.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Embedded content.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Contexts in which this element can be used:
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Where embedded content is expected.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Content model:
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Transparent.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Transparent, but with no interactive content descendants except for a elements, button elements, input elements whose type attribute are in the Checkbox or Radio Button states, and input elements that are buttons.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Content attributes:
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Global attributes
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              width
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              height
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              DOM interface:
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              interface HTMLCanvasElement : HTMLElement {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +           attribute unsigned long width;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +           attribute unsigned long height;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  DOMString toDataURL(in optional DOMString type, in any... args);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void toBlob(in FileCallback? callback, in optional DOMString type, in any... args);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  object? getContext(in DOMString contextId, in any... args);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +};
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The canvas element provides scripts with a + resolution-dependent bitmap canvas, which can be used for rendering + graphs, game graphics, or other visual images on the fly.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Authors should not use the canvas element in a + document when a more suitable element is available. For example, it + is inappropriate to use a canvas element to render a + page heading: if the desired presentation of the heading is + graphically intense, it should be marked up using appropriate + elements (typically h1) and then styled using CSS and + supporting technologies such as XBL.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When authors use the canvas element, they must also + provide content that, when presented to the user, conveys + essentially the same function or purpose as the bitmap canvas. This + content may be placed as content of the canvas + element. The contents of the canvas element, if any, + are the element's fallback content.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              In interactive visual media, if scripting is enabled for the + canvas element, and if support for canvas + elements has been enabled, the canvas element + represents embedded content consisting of + a dynamically created image.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              In non-interactive, static, visual media, if the + canvas element has been previously painted on (e.g. if + the page was viewed in an interactive visual medium and is now being + printed, or if some script that ran during the page layout process + painted on the element), then the canvas element + represents embedded content with the + current image and size. Otherwise, the element represents its + fallback content instead.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              In non-visual media, and in visual media if scripting is disabled for the + canvas element or if support for canvas + elements has been disabled, the canvas element + represents its fallback content + instead.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When a canvas element represents + embedded content, the user can still focus descendants + of the canvas element (in the fallback + content). When an element is focused, it is the target of + keyboard interaction events (even though the element itself is not + visible). This allows authors to make an interactive canvas + keyboard-accessible: authors should have a one-to-one mapping of + interactive regions to focusable elements in the fallback + content. (Focus has no effect on mouse interaction + events.) [DOMEVENTS]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The canvas element has two attributes to control the + size of the coordinate space: width and height. These + attributes, when specified, must have values that are valid non-negative + integers. The rules for parsing + non-negative integers must be used to obtain their numeric + values. If an attribute is missing, or if parsing its value returns + an error, then the default value must be used instead. The + width attribute defaults to + 300, and the height + attribute defaults to 150.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The intrinsic dimensions of the canvas element equal + the size of the coordinate space, with the numbers interpreted in + CSS pixels. However, the element can be sized arbitrarily by a + style sheet. During rendering, the image is scaled to fit this layout + size.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The size of the coordinate space does not necessarily represent + the size of the actual bitmap that the user agent will use + internally or during rendering. On high-definition displays, for + instance, the user agent may internally use a bitmap with two device + pixels per unit in the coordinate space, so that the rendering + remains at high quality throughout.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When the canvas element is created, and subsequently + whenever the width and height attributes are set (whether + to a new value or to the previous value), the bitmap and any + associated contexts must be cleared back to their initial state and + reinitialized with the newly specified coordinate space + dimensions.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When the canvas is initialized, its bitmap must be cleared to + transparent black.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The width and + height IDL + attributes must reflect the respective content + attributes of the same name, with the same defaults.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Only one square appears to be drawn in the following example:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                // canvas is a reference to a <canvas> element
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  var context = canvas.getContext('2d');
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  context.fillRect(0,0,50,50);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  canvas.setAttribute('width', '300'); // clears the canvas
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  context.fillRect(0,100,50,50);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  canvas.width = canvas.width; // clears the canvas
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  context.fillRect(100,0,50,50); // only this square remains
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context = canvas . getContext(contextId [, ... ])
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns an object that exposes an API for drawing on the + canvas. The first argument specifies the desired API. Subsequent + arguments are handled by that API.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              This specification defines the "2d" context below. There is also + a specification that defines a "webgl" context. [WEBGL]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The list of defined contexts is given on the WHATWG Wiki + CanvasContexts page. [WHATWGWIKI] + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns null if the given context ID is not supported or if the + canvas has already been initialized with some other (incompatible) + context type (e.g. trying to get a "2d" context after getting a + "webgl" context).

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              A canvas element can have a primary + context, which is the first context to have been obtained for + that element. When created, a canvas element must not + have a primary context.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The getContext(contextId, args...) + method of the canvas element, when invoked, must run + the following steps:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              1. Let contextId be the first argument to + the method.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              3. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If contextId is not the name of a context + supported by the user agent, return null and abort these + steps.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                An example of this would be a user agent that + theoretically supports the "webgl" 3D context, in the case + where the platform does not have hardware support for OpenGL and + the user agent does not have a software OpenGL implementation. + Despite the user agent recognising the "webgl" name, it would return + null at this step because that context is not, in practice, + supported at the time of the call.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              5. If the element has a primary context and that + context's entry in the WHATWG Wiki + CanvasContexts page does not list contextId + as a context with which it is compatible, return null and abort + these steps. [WHATWGWIKI]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              6. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              7. If the element does not have a primary context, + let the element's primary context be contextId.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              8. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              9. If the getContext() method has + already been invoked on this element for the same contextId, return the same object as was returned + that time, and abort these steps. The additional arguments are + ignored.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              10. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              11. Return a new object for contextId, as defined by the specification + given for contextId's entry in the WHATWG Wiki + CanvasContexts page. [WHATWGWIKI]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              12. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              New context types may be registered in the WHATWG Wiki + CanvasContexts page. [WHATWGWIKI]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Anyone is free to edit the WHATWG Wiki CanvasContexts page at any + time to add a new context type. These new context types must be + specified with the following information:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Keyword
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The value of contextID that will return + the object for the new API.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Specification
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              A link to a formal specification of the context type's + API. It could be another page on the Wiki, or a link to an external + page. If the type does not have a formal specification, an informal + description can be substituted until such time as a formal + specification is available.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Compatible with
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The list of context types that are compatible with this one + (i.e. that operate on the same underlying bitmap). This list must + be transitive and symmetric; if one context type is defined as + compatible with another, then all types it is compatible with must + be compatible with all types the other is compatible with.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Vendors may also define experimental contexts using the syntax + vendorname-context, for example, + moz-3d. Such contexts should be registered in the + WHATWG Wiki CanvasContexts page.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              url = canvas . toDataURL( [ type, ... ])
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns a data: URL for the image in the canvas.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The first argument, if provided, controls the type of the image + to be returned (e.g. PNG or JPEG). The default is image/png; that type is also used if the given + type isn't supported. The other arguments are specific to the + type, and control the way that the image is generated, as given in + the table below.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When trying to use types other than "image/png", + authors can check if the image was really returned in the + requested format by checking to see if the returned string starts + with one of the exact strings "data:image/png," or "data:image/png;". If it does, the image is PNG, + and thus the requested type was not supported. (The one exception + to this is if the canvas has either no height or no width, in + which case the result might simply be "data:,".)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              canvas . toBlob(callback [, type, ... ])
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Creates a Blob object representing a file + containing the image in the canvas, and invokes a callback with a + handle to that object.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The second argument, if provided, controls the type of the + image to be returned (e.g. PNG or JPEG). The default is image/png; that type is also used if the given + type isn't supported. The other arguments are specific to the + type, and control the way that the image is generated, as given in + the table below.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The toDataURL() method + must run the following steps:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              1. If the canvas has no pixels (i.e. either its horizontal + dimension or its vertical dimension is zero) then return the string + "data:," and abort these steps. (This is the + shortest data: + URL; it represents the empty string in a text/plain resource.)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              3. Let file be a serialization of the + image as a file, using the method's arguments (if any) as + the arguments.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              5. Return a data: URL representing file. [RFC2397]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The toBlob() method + must run the following steps:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              1. Let callback be the first + argument.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              3. Let arguments be the second and + subsequent arguments to the method, if any.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              5. Let file be a serialization of the + image as a file, using arguments.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              6. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              7. Return, but continue running these steps + asynchronously.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              8. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              9. If callback is null, abort these + steps.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              10. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              11. Queue a task to invoke the + FileCallback callback with a + Blob object representing file as + its argument. The task source for this task is the + canvas blob serialization task source. [FILESYSTEMAPI] [FILEAPI]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              12. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When a user agent is to create a serialization of the image + as a file, optionally with some given arguments, it must create an image file in the format + given by the first value of arguments, or, if + there are no arguments, in the PNG format. [PNG]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If arguments is not empty, the first value + must be interpreted as a MIME type + giving the format to use. If the type has any parameters, it must be + treated as not supported.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              For example, the value "image/png" would + mean to generate a PNG image, the value "image/jpeg" + would mean to generate a JPEG image, and the value + "image/svg+xml" would mean to generate an SVG image + (which would probably require that the implementation actually keep + enough information to reliably render an SVG image from the canvas).

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              User agents must support PNG ("image/png"). User + agents may support other types. If the user agent does not support + the requested type, it must create the file using the PNG format. [PNG]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              User agents must convert the provided type to ASCII lowercase + before establishing if they support that type.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              For image types that do not support an alpha channel, the + serialized image must be the canvas image composited onto a solid + black background using the source-over operator.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If the first argument in arguments gives a + type corresponding to one of the types given in the first column of + the following table, and the user agent supports that type, then the + subsequent arguments, if any, must be treated as described in the + second cell of that row.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Type Other arguments Reference +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              image/jpeg + The second argument, if it is a + number in the range 0.0 to 1.0 inclusive, must + be treated as the desired quality level. If it is not a number or is outside that range, the + user agent must use its default value, as if the argument had + been omitted. + [JPEG] +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              For the purposes of these rules, an argument is considered to be + a number if it is converted to an IDL double value by the rules for + handling arguments of type any in the Web IDL + specification. [WEBIDL]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Other arguments must be ignored and must not cause the user agent + to raise an exception. A future version of this specification will + probably define other parameters to be passed to these methods to + allow authors to more carefully control compression settings, image + metadata, etc.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4.8.11.1 The 2D context
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              This specification defines the 2d context type, whose + API is implemented using the CanvasRenderingContext2D + interface.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When the getContext() + method of a canvas element is to return a new object for the contextId 2d, the user agent must return a + new CanvasRenderingContext2D object. Any additional + arguments are ignored.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The 2D context represents a flat Cartesian surface whose origin + (0,0) is at the top left corner, with the coordinate space having + x values increasing when going right, and y values increasing when going down.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              interface CanvasRenderingContext2D {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  // back-reference to the canvas
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  readonly attribute HTMLCanvasElement canvas;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  // state
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void save(); // push state on state stack
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void restore(); // pop state stack and restore state
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  // transformations (default transform is the identity matrix)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void scale(in double x, in double y);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void rotate(in double angle);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void translate(in double x, in double y);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void transform(in double a, in double b, in double c, in double d, in double e, in double f);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void setTransform(in double a, in double b, in double c, in double d, in double e, in double f);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  // compositing
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +           attribute double globalAlpha; // (default 1.0)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +           attribute DOMString globalCompositeOperation; // (default source-over)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  // colors and styles
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +           attribute any strokeStyle; // (default black)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +           attribute any fillStyle; // (default black)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  CanvasGradient createLinearGradient(in double x0, in double y0, in double x1, in double y1);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  CanvasGradient createRadialGradient(in double x0, in double y0, in double r0, in double x1, in double y1, in double r1);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  CanvasPattern createPattern(in HTMLImageElement image, in DOMString repetition);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  CanvasPattern createPattern(in HTMLCanvasElement image, in DOMString repetition);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  CanvasPattern createPattern(in HTMLVideoElement image, in DOMString repetition);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  // line caps/joins
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +           attribute double lineWidth; // (default 1)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +           attribute DOMString lineCap; // "butt", "round", "square" (default "butt")
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +           attribute DOMString lineJoin; // "round", "bevel", "miter" (default "miter")
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +           attribute double miterLimit; // (default 10)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  // shadows
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +           attribute double shadowOffsetX; // (default 0)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +           attribute double shadowOffsetY; // (default 0)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +           attribute double shadowBlur; // (default 0)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +           attribute DOMString shadowColor; // (default transparent black)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  // rects
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void clearRect(in double x, in double y, in double w, in double h);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void fillRect(in double x, in double y, in double w, in double h);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void strokeRect(in double x, in double y, in double w, in double h);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  // path API
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void beginPath();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void closePath();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void moveTo(in double x, in double y);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void lineTo(in double x, in double y);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void quadraticCurveTo(in double cpx, in double cpy, in double x, in double y);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void bezierCurveTo(in double cp1x, in double cp1y, in double cp2x, in double cp2y, in double x, in double y);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void arcTo(in double x1, in double y1, in double x2, in double y2, in double radius);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void rect(in double x, in double y, in double w, in double h);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void arc(in double x, in double y, in double radius, in double startAngle, in double endAngle, in optional boolean anticlockwise);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void fill();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void stroke();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void drawSystemFocusRing(in Element element);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  boolean drawCustomFocusRing(in Element element);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void scrollPathIntoView();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void clip();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  boolean isPointInPath(in double x, in double y);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  // text
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +           attribute DOMString font; // (default 10px sans-serif)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +           attribute DOMString textAlign; // "start", "end", "left", "right", "center" (default: "start")
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +           attribute DOMString textBaseline; // "top", "hanging", "middle", "alphabetic", "ideographic", "bottom" (default: "alphabetic")
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void fillText(in DOMString text, in double x, in double y, in optional double maxWidth);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void strokeText(in DOMString text, in double x, in double y, in optional double maxWidth);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  TextMetrics measureText(in DOMString text);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  // drawing images
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void drawImage(in HTMLImageElement image, in double dx, in double dy);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void drawImage(in HTMLImageElement image, in double dx, in double dy, in double dw, in double dh);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void drawImage(in HTMLImageElement image, in double sx, in double sy, in double sw, in double sh, in double dx, in double dy, in double dw, in double dh);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void drawImage(in HTMLCanvasElement image, in double dx, in double dy);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void drawImage(in HTMLCanvasElement image, in double dx, in double dy, in double dw, in double dh);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void drawImage(in HTMLCanvasElement image, in double sx, in double sy, in double sw, in double sh, in double dx, in double dy, in double dw, in double dh);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void drawImage(in HTMLVideoElement image, in double dx, in double dy);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void drawImage(in HTMLVideoElement image, in double dx, in double dy, in double dw, in double dh);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void drawImage(in HTMLVideoElement image, in double sx, in double sy, in double sw, in double sh, in double dx, in double dy, in double dw, in double dh);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  // pixel manipulation
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  ImageData createImageData(in double sw, in double sh);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  ImageData createImageData(in ImageData imagedata);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  ImageData getImageData(in double sx, in double sy, in double sw, in double sh);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void putImageData(in ImageData imagedata, in double dx, in double dy);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void putImageData(in ImageData imagedata, in double dx, in double dy, in double dirtyX, in double dirtyY, in double dirtyWidth, in double dirtyHeight);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +};
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +interface CanvasGradient {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  // opaque object
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  void addColorStop(in double offset, in DOMString color);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +};
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +interface CanvasPattern {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  // opaque object
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +};
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +interface TextMetrics {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  readonly attribute double width;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +};
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +interface ImageData {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  readonly attribute unsigned long width;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  readonly attribute unsigned long height;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  readonly attribute CanvasPixelArray data;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +};
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +interface CanvasPixelArray {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  readonly attribute unsigned long length;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  getter octet (in unsigned long index);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  setter void (in unsigned long index, [Clamp] in octet value);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +};
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . canvas
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns the canvas element.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The canvas + attribute must return the canvas element that the + context paints on.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Except where otherwise specified, for the 2D context interface, + any method call with a numeric argument whose value is infinite or a + NaN value must be ignored.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Whenever the CSS value currentColor is used + as a color in this API, the "computed value of the 'color' property" + for the purposes of determining the computed value of the currentColor keyword is the computed value of the + 'color' property on the element in question at the time that the + color is specified (e.g. when the appropriate attribute is set, or + when the method is called; not when the color is rendered or + otherwise used). If the computed value of the 'color' property is + undefined for a particular case (e.g. because the element is not + in a Document), then the "computed value + of the 'color' property" for the purposes of determining the + computed value of the currentColor keyword is + fully opaque black. [CSSCOLOR]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              In the case of addColorStop() on + CanvasGradient, the "computed value of the 'color' + property" for the purposes of determining the computed value of the + currentColor keyword is always fully opaque + black (there is no associated element). [CSSCOLOR]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              This is because CanvasGradient objects + are canvas-neutral — a + CanvasGradient object created by one + canvas can be used by another, and there is therefore + no way to know which is the "element in question" at the time that + the color is specified.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4.8.11.1.1 The canvas state
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Each context maintains a stack of drawing states. Drawing states consist of:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The current path and the current bitmap are not part + of the drawing state. The current path is persistent, and can only + be reset using the beginPath() method. The + current bitmap is a property of the canvas, not the context.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . save()
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Pushes the current state onto the stack.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . restore()
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Pops the top state on the stack, restoring the context to that state.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The save() + method must push a copy of the current drawing state onto the + drawing state stack.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The restore() method + must pop the top entry in the drawing state stack, and reset the + drawing state it describes. If there is no saved state, the method + must do nothing.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4.8.11.1.2 Transformations
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The transformation matrix is applied to coordinates when creating + shapes and paths.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When the context is created, the transformation matrix must + initially be the identity transform. It may then be adjusted using + the transformation methods.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The transformations must be performed in reverse order. For + instance, if a scale transformation that doubles the width is + applied, followed by a rotation transformation that rotates drawing + operations by a quarter turn, and a rectangle twice as wide as it is + tall is then drawn on the canvas, the actual result will be a + square.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . scale(x, y)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Changes the transformation matrix to apply a scaling transformation with the given characteristics.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . rotate(angle)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Changes the transformation matrix to apply a rotation transformation with the given characteristics. The angle is in radians.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . translate(x, y)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Changes the transformation matrix to apply a translation transformation with the given characteristics.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . transform(a, b, c, d, e, f)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Changes the transformation matrix to apply the matrix given by the arguments as described below.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . setTransform(a, b, c, d, e, f)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Changes the transformation matrix to the matrix given by the arguments as described below.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The scale(x, y) method must + add the scaling transformation described by the arguments to the + transformation matrix. The x argument represents + the scale factor in the horizontal direction and the y argument represents the scale factor in the + vertical direction. The factors are multiples.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The rotate(angle) method must add the rotation + transformation described by the argument to the transformation + matrix. The angle argument represents a + clockwise rotation angle expressed in radians.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The translate(x, y) method must + add the translation transformation described by the arguments to the + transformation matrix. The x argument represents + the translation distance in the horizontal direction and the y argument represents the translation distance in the + vertical direction. The arguments are in coordinate space units.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The transform(a, b, c, d, e, f) method must replace the current + transformation matrix with the result of multiplying the current + transformation matrix with the matrix described by:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + + + + + + + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              ace
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              bdf
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              001

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The arguments a, b, c, d, e, and f are sometimes called + m11, m12, m21, m22, dx, + and dy or m11, m21, m12, m22, dx, and dy. Care should be taken in particular with the order + of the second and third arguments (b and c) as their order varies from API to API and APIs + sometimes use the notation m12/m21 and sometimes m21/m12 for those positions.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The setTransform(a, b, c, d, e, + f) method must reset the current + transform to the identity matrix, and then invoke the transform(a, b, c, d, e, + f) method with the same arguments.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4.8.11.1.3 Compositing
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . globalAlpha [ = value ]
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns the current alpha value applied to rendering operations.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Can be set, to change the alpha value. Values outside of the + range 0.0 .. 1.0 are ignored.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . globalCompositeOperation [ = value ]
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns the current composition operation, from the list below.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Can be set, to change the composition operation. Unknown values + are ignored.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              All drawing operations are affected by the global compositing + attributes, globalAlpha and globalCompositeOperation.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The globalAlpha + attribute gives an alpha value that is applied to shapes and images + before they are composited onto the canvas. The value must be in the + range from 0.0 (fully transparent) to 1.0 (no additional + transparency). If an attempt is made to set the attribute to a value + outside this range, including Infinity and Not-a-Number (NaN) + values, the attribute must retain its previous value. When the + context is created, the globalAlpha attribute must + initially have the value 1.0.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The globalCompositeOperation + attribute sets how shapes and images are drawn onto the existing + bitmap, once they have had globalAlpha and the + current transformation matrix applied. It must be set to a value + from the following list. In the descriptions below, the source + image, A, is the shape or image being rendered, + and the destination image, B, is the current + state of the bitmap.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              source-atop
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              A atop B. Display the + source image wherever both images are opaque. Display the + destination image wherever the destination image is opaque but the + source image is transparent. Display transparency elsewhere.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              source-in
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              A in B. Display the + source image wherever both the source image and destination image + are opaque. Display transparency elsewhere.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              source-out
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              A out B. Display the + source image wherever the source image is opaque and the + destination image is transparent. Display transparency + elsewhere.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              source-over (default)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              A over B. Display the + source image wherever the source image is opaque. Display the + destination image elsewhere.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              destination-atop
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              B atop A. Same as source-atop but using the + destination image instead of the source image and vice versa.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              destination-in
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              B in A. Same as source-in but using the destination + image instead of the source image and vice versa.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              destination-out
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              B out A. Same as source-out but using the destination + image instead of the source image and vice versa.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              destination-over
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              B over A. Same as source-over but using the + destination image instead of the source image and vice versa.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              lighter
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              A plus B. Display the + sum of the source image and destination image, with color values + approaching 255 (100%) as a limit.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              copy
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              A (B is + ignored). Display the source image instead of the destination + image.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              xor
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              A xor B. Exclusive OR + of the source image and destination image.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              vendorName-operationName
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Vendor-specific extensions to the list of + composition operators should use this syntax.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The operators in the above list must be treated as described by + the Porter-Duff operator given at the start of their description + (e.g. A over B). They are to + be applied as part of the drawing model, at which point the + clipping region is also applied. (Without a clipping + region, these operators act on the whole bitmap with every + operation.) [PORTERDUFF]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              These values are all case-sensitive — they must be used + exactly as shown. User agents must not recognize values that are not + a case-sensitive match for one of the values given + above.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              On setting, if the user agent does not recognize the specified + value, it must be ignored, leaving the value of globalCompositeOperation + unaffected.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When the context is created, the globalCompositeOperation + attribute must initially have the value + source-over.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4.8.11.1.4 Colors and styles
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . strokeStyle [ = value ]
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns the current style used for stroking shapes.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Can be set, to change the stroke style.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The style can be either a string containing a CSS color, or a + CanvasGradient or CanvasPattern + object. Invalid values are ignored.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . fillStyle [ = value ]
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns the current style used for filling shapes.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Can be set, to change the fill style.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The style can be either a string containing a CSS color, or a + CanvasGradient or CanvasPattern + object. Invalid values are ignored.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The strokeStyle + attribute represents the color or style to use for the lines around + shapes, and the fillStyle + attribute represents the color or style to use inside the + shapes.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Both attributes can be either strings, + CanvasGradients, or CanvasPatterns. On + setting, strings must be parsed as CSS <color> values and the color + assigned, and CanvasGradient and + CanvasPattern objects must be assigned themselves. [CSSCOLOR] If the value is a string but + cannot be parsed as a CSS <color> value, or is + neither a string, a CanvasGradient, nor a + CanvasPattern, then it must be ignored, and the + attribute must retain its previous value.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When set to a CanvasPattern or + CanvasGradient object, the assignment is + live, meaning that changes made to the object after the + assignment do affect subsequent stroking or filling of shapes.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              On getting, if the value is a color, then the serialization of the color + must be returned. Otherwise, if it is not a color but a + CanvasGradient or CanvasPattern, then the + respective object must be returned. (Such objects are opaque and + therefore only useful for assigning to other attributes or for + comparison to other gradients or patterns.)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The serialization of a color for a color value is a + string, computed as follows: if it has alpha equal to 1.0, then the + string is a lowercase six-digit hex value, prefixed with a "#" + character (U+0023 NUMBER SIGN), with the first two digits + representing the red component, the next two digits representing the + green component, and the last two digits representing the blue + component, the digits being in the range 0-9 a-f (U+0030 to U+0039 + and U+0061 to U+0066). Otherwise, the color value has alpha less + than 1.0, and the string is the color value in the CSS rgba() functional-notation format: the literal + string rgba (U+0072 U+0067 U+0062 U+0061) + followed by a U+0028 LEFT PARENTHESIS, a base-ten integer in the + range 0-255 representing the red component (using digits 0-9, U+0030 + to U+0039, in the shortest form possible), a literal U+002C COMMA + and U+0020 SPACE, an integer for the green component, a comma and a + space, an integer for the blue component, another comma and space, a + U+0030 DIGIT ZERO, if the alpha value is greater than zero then a + U+002E FULL STOP (representing the decimal point), if the alpha + value is greater than zero then one or more digits in the range 0-9 + (U+0030 to U+0039) representing the fractional part of the alpha + value, and finally a U+0029 RIGHT PARENTHESIS.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When the context is created, the strokeStyle and fillStyle attributes must + initially have the string value #000000.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              There are two types of gradients, linear gradients and radial + gradients, both represented by objects implementing the opaque + CanvasGradient interface.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Once a gradient has been created (see below), + stops are placed along it to define how the colors are distributed + along the gradient. The color of the gradient at + each stop is the color specified for that stop. Between each such + stop, the colors and the alpha component must be linearly + interpolated over the RGBA space without premultiplying the alpha + value to find the color to use at that offset. Before the first + stop, the color must be the color of the first stop. After the last + stop, the color must be the color of the last stop. When there are + no stops, the gradient is transparent black.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              gradient . addColorStop(offset, color)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Adds a color stop with the given color to the gradient at the + given offset. 0.0 is the offset at one end of the gradient, 1.0 is + the offset at the other end.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Throws an INDEX_SIZE_ERR exception if the offset + is out of range. Throws a SYNTAX_ERR exception if the + color cannot be parsed.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              gradient = context . createLinearGradient(x0, y0, x1, y1)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns a CanvasGradient object that represents a + linear gradient that paints along the line given by the + coordinates represented by the arguments.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If any of the arguments are not finite numbers, throws a + NOT_SUPPORTED_ERR exception.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              gradient = context . createRadialGradient(x0, y0, r0, x1, y1, r1)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns a CanvasGradient object that represents a + radial gradient that paints along the cone given by the circles + represented by the arguments.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If any of the arguments are not finite numbers, throws a + NOT_SUPPORTED_ERR exception. If either of the radii + are negative, throws an INDEX_SIZE_ERR exception.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The addColorStop(offset, color) + method on the CanvasGradient interface adds a new stop + to a gradient. If the offset is less than 0, + greater than 1, infinite, or NaN, then an + INDEX_SIZE_ERR exception must be raised. If the color cannot be parsed as a CSS <color> + value, then a SYNTAX_ERR exception must be + raised. Otherwise, the gradient must have a new stop placed, at + offset offset relative to the whole gradient, + and with the color obtained by parsing color as + a CSS <color> value. If multiple stops are added at the same + offset on a gradient, they must be placed in the order added, with + the first one closest to the start of the gradient, and each + subsequent one infinitesimally further along towards the end point + (in effect causing all but the first and last stop added at each + point to be ignored).

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The createLinearGradient(x0, y0, x1, + y1) method takes four arguments + that represent the start point (x0, y0) and end point (x1, y1) of the gradient. If any of the arguments to createLinearGradient() + are infinite or NaN, the method must raise a + NOT_SUPPORTED_ERR exception. Otherwise, the method must + return a linear CanvasGradient initialized with the + specified line.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Linear gradients must be rendered such that all points on a line + perpendicular to the line that crosses the start and end points have + the color at the point where those two lines cross (with the colors + coming from the interpolation and + extrapolation described above). The points in the linear + gradient must be transformed as described by the current transformation + matrix when rendering.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If x0 = x1 and y0 = y1, then + the linear gradient must paint nothing.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The createRadialGradient(x0, y0, r0, + x1, y1, r1) method takes six arguments, the + first three representing the start circle with origin (x0, y0) and radius r0, and the last three representing the end circle + with origin (x1, y1) and + radius r1. The values are in coordinate space + units. If any of the arguments are infinite or NaN, a + NOT_SUPPORTED_ERR exception must be raised. If either + of r0 or r1 are negative, an + INDEX_SIZE_ERR exception must be raised. Otherwise, + the method must return a radial CanvasGradient + initialized with the two specified circles.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Radial gradients must be rendered by following these steps:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              1. If x0 = x1 and y0 = y1 and r0 = r1, then the radial gradient must + paint nothing. Abort these steps.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              3. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Let x(ω) = (x1-x0)ω + x0

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Let y(ω) = (y1-y0)ω + y0

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Let r(ω) = (r1-r0)ω + r0

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Let the color at ω be the color at + that position on the gradient (with the colors coming from the interpolation and extrapolation + described above).

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              5. For all values of ω where r(ω) > 0, + starting with the value of ω nearest to + positive infinity and ending with the value of ω nearest to negative infinity, draw the + circumference of the circle with radius r(ω) at position (x(ω), y(ω)), with the color at ω, but only painting on the parts of the + canvas that have not yet been painted on by earlier circles in this + step for this rendering of the gradient.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              6. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              This effectively creates a cone, touched by the two + circles defined in the creation of the gradient, with the part of + the cone before the start circle (0.0) using the color of the first + offset, the part of the cone after the end circle (1.0) using the + color of the last offset, and areas outside the cone untouched by + the gradient (transparent black).

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The points in the radial gradient must be transformed as + described by the current + transformation matrix when rendering.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Gradients must be painted only where the relevant stroking or + filling effects requires that they be drawn.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Patterns are represented by objects implementing the opaque + CanvasPattern interface.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              pattern = context . createPattern(image, repetition)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns a CanvasPattern object that uses the given image + and repeats in the direction(s) given by the repetition argument.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The allowed values for repetition are repeat (both directions), repeat-x (horizontal only), repeat-y (vertical only), and no-repeat (neither). If the repetition argument is empty, the value repeat is used.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If the image has no image data, throws an + INVALID_STATE_ERR exception. If the second argument + isn't one of the allowed values, throws a SYNTAX_ERR + exception. If the image isn't yet fully decoded, then the method + returns null.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              To create objects of this type, the createPattern(image, repetition) + method is used. The first argument gives the image to use as the + pattern (either an HTMLImageElement, + HTMLCanvasElement, or HTMLVideoElement + object). Modifying this image after calling the createPattern() method + must not affect the pattern. The second argument must be a string + with one of the following values: repeat, + repeat-x, repeat-y, + no-repeat. If the empty string is specified, + repeat must be assumed. If an unrecognized value + is given, then the user agent must raise a SYNTAX_ERR + exception. User agents must recognize the four values described above + exactly (e.g. they must not do case folding). Except as specified + below, the method must return a CanvasPattern object + suitably initialized.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The image argument is an instance of either + HTMLImageElement, HTMLCanvasElement, or + HTMLVideoElement.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If the image argument is an + HTMLImageElement object that is not fully decodable, or if the image argument is an HTMLVideoElement + object whose readyState + attribute is either HAVE_NOTHING or HAVE_METADATA, then the + implementation must return null.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If the image argument is an + HTMLCanvasElement object with either a horizontal + dimension or a vertical dimension equal to zero, then the + implementation must raise an INVALID_STATE_ERR + exception.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Patterns must be painted so that the top left of the first image + is anchored at the origin of the coordinate space, and images are + then repeated horizontally to the left and right (if the + repeat-x string was specified) or vertically up and + down (if the repeat-y string was specified) or in all + four directions all over the canvas (if the repeat + string was specified). The images are not scaled by this process; + one CSS pixel of the image must be painted on one coordinate space + unit. Of course, patterns must actually be painted only where the + stroking or filling effect requires that they be drawn, and are + affected by the current transformation matrix.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If the original image data is a bitmap image, the value painted + at a point in the area of the repetitions is computed by filtering + the original image data. The user agent may use any filtering + algorithm (for example bilinear interpolation or nearest-neighbor). + When the filtering algorithm requires a pixel value from outside the + original image data, it must instead use the value from wrapping the + pixel's coordinates to the original image's dimensions. (That is, + the filter uses 'repeat' behavior, regardless of the value of + repetition.) + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When the createPattern() method + is passed an animated image as its image + argument, the user agent must use the poster frame of the animation, + or, if there is no poster frame, the first frame of the + animation.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When the image argument is an + HTMLVideoElement, then the frame at the current + playback position must be used as the source image, and the + source image's dimensions must be the intrinsic width and + intrinsic height + of the media resource (i.e. after any aspect-ratio + correction has been applied).

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4.8.11.1.5 Line styles
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . lineWidth [ = value ]
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns the current line width.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Can be set, to change the line width. Values that are not + finite values greater than zero are ignored.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . lineCap [ = value ]
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns the current line cap style.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Can be set, to change the line cap style.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The possible line cap styles are butt, + round, and square. Other values are + ignored.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . lineJoin [ = value ]
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns the current line join style.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Can be set, to change the line join style.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The possible line join styles are bevel, + round, and miter. Other values are + ignored.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . miterLimit [ = value ]
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns the current miter limit ratio.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Can be set, to change the miter limit ratio. Values that are + not finite values greater than zero are ignored.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The lineWidth + attribute gives the width of lines, in coordinate space units. On + getting, it must return the current value. On setting, zero, + negative, infinite, and NaN values must be ignored, leaving the + value unchanged; other values must change the current value to the + new value.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When the context is created, the lineWidth attribute must + initially have the value 1.0.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The lineCap attribute + defines the type of endings that UAs will place on the end of + lines. The three valid values are butt, + round, and square. The butt + value means that the end of each line has a flat edge perpendicular + to the direction of the line (and that no additional line cap is + added). The round value means that a semi-circle with + the diameter equal to the width of the line must then be added on to + the end of the line. The square value means that a + rectangle with the length of the line width and the width of half + the line width, placed flat against the edge perpendicular to the + direction of the line, must be added at the end of each line.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              On getting, it must return the current value. On setting, if the + new value is one of the literal strings butt, + round, and square, then the current value + must be changed to the new value; other values must ignored, leaving + the value unchanged.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When the context is created, the lineCap attribute must + initially have the value butt.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The lineJoin + attribute defines the type of corners that UAs will place where two + lines meet. The three valid values are bevel, + round, and miter.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              On getting, it must return the current value. On setting, if the + new value is one of the literal strings bevel, + round, and miter, then the current value + must be changed to the new value; other values must be ignored, + leaving the value unchanged.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When the context is created, the lineJoin attribute must + initially have the value miter.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              A join exists at any point in a subpath shared by two consecutive + lines. When a subpath is closed, then a join also exists at its + first point (equivalent to its last point) connecting the first and + last lines in the subpath.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              In addition to the point where the join occurs, two additional + points are relevant to each join, one for each line: the two corners + found half the line width away from the join point, one + perpendicular to each line, each on the side furthest from the other + line.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              A filled triangle connecting these two opposite corners with a + straight line, with the third point of the triangle being the join + point, must be rendered at all joins. The lineJoin attribute controls + whether anything else is rendered. The three aforementioned values + have the following meanings:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The bevel value means that this is all that is + rendered at joins.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The round value means that a filled arc connecting + the two aforementioned corners of the join, abutting (and not + overlapping) the aforementioned triangle, with the diameter equal to + the line width and the origin at the point of the join, must be + rendered at joins.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The miter value means that a second filled triangle + must (if it can given the miter length) be rendered at the join, + with one line being the line between the two aforementioned corners, + abutting the first triangle, and the other two being continuations of + the outside edges of the two joining lines, as long as required to + intersect without going over the miter length.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The miter length is the distance from the point where the join + occurs to the intersection of the line edges on the outside of the + join. The miter limit ratio is the maximum allowed ratio of the + miter length to half the line width. If the miter length would cause + the miter limit ratio to be exceeded, this second triangle must not + be rendered.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The miter limit ratio can be explicitly set using the miterLimit + attribute. On getting, it must return the current value. On setting, + zero, negative, infinite, and NaN values must be ignored, leaving + the value unchanged; other values must change the current value to + the new value.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When the context is created, the miterLimit attribute must + initially have the value 10.0.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4.8.11.1.6 Shadows
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              All drawing operations are affected by the four global shadow + attributes.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . shadowColor [ = value ]
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns the current shadow color.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Can be set, to change the shadow color. Values that cannot be parsed as CSS colors are ignored.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . shadowOffsetX [ = value ]
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . shadowOffsetY [ = value ]
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns the current shadow offset.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Can be set, to change the shadow offset. Values that are not finite numbers are ignored.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . shadowBlur [ = value ]
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns the current level of blur applied to shadows.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Can be set, to change the blur level. Values that are not finite numbers greater than or equal to zero are ignored.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The shadowColor + attribute sets the color of the shadow.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When the context is created, the shadowColor attribute + initially must be fully-transparent black.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              On getting, the serialization of the color must be returned.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              On setting, the new value must be parsed as a CSS + <color> value and the color assigned. If the value + cannot be parsed as a CSS <color> value then it must be + ignored, and the attribute must retain its previous value. [CSSCOLOR]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The shadowOffsetX + and shadowOffsetY + attributes specify the distance that the shadow will be offset in + the positive horizontal and positive vertical distance + respectively. Their values are in coordinate space units. They are + not affected by the current transformation matrix.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When the context is created, the shadow offset attributes must + initially have the value 0.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              On getting, they must return their current value. On setting, the + attribute being set must be set to the new value, except if the + value is infinite or NaN, in which case the new value must be + ignored.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The shadowBlur + attribute specifies the level of the blurring effect. (The units do + not map to coordinate space units, and are not affected by the + current transformation matrix.)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When the context is created, the shadowBlur attribute must + initially have the value 0.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              On getting, the attribute must return its current value. On + setting the attribute must be set to the new value, except if the + value is negative, infinite or NaN, in which case the new value must + be ignored.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Shadows are only drawn + if the opacity component of the alpha component of the color + of shadowColor is + non-zero and either the shadowBlur is non-zero, or + the shadowOffsetX + is non-zero, or the shadowOffsetY is + non-zero.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              It is likely that this will change: browser + vendors have indicated an interest in changing the processing model + for shadows such that they only draw when the composition operator + is "source-over" (the default). Read + more...

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When shadows are drawn, they must be rendered as follows:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              1. Let A be an infinite transparent black + bitmap on which the source image for which a shadow is being + created has been rendered.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              3. Let B be an infinite transparent black + bitmap, with a coordinate space and an origin identical to A.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              5. Copy the alpha channel of A to B, offset by shadowOffsetX in the + positive x direction, and shadowOffsetY in the + positive y direction.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              6. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              7. If shadowBlur is greater than + 0:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                1. Let σ be half the value of + shadowBlur.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                3. Perform a 2D Gaussian Blur on B, + using σ as the standard deviation.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                4. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                User agents may limit values of σ to + an implementation-specific maximum value to avoid exceeding + hardware limitations during the Gaussian blur operation.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              8. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              9. Set the red, green, and blue components of every pixel in + B to the red, green, and blue components + (respectively) of the color of shadowColor.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              10. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              11. Multiply the alpha component of every pixel in B by the alpha component of the color of shadowColor.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              12. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              13. The shadow is in the bitmap B, and is + rendered as part of the drawing model described below.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              14. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If the current composition operation is copy, shadows effectively won't render + (since the shape will overwrite the shadow).

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4.8.11.1.7 Simple shapes (rectangles)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              There are three methods that immediately draw rectangles to the + bitmap. They each take four arguments; the first two give the x and y coordinates of the top + left of the rectangle, and the second two give the width w and height h of the rectangle, + respectively.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The current + transformation matrix must be applied to the following four + coordinates, which form the path that must then be closed to get the + specified rectangle: (x, y), (x+w, y), + (x+w, + y+h), + (x, y+h).

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Shapes are painted without affecting the current path, and are + subject to the clipping region, + and, with the exception of clearRect(), also shadow effects, global alpha, and global composition + operators.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . clearRect(x, y, w, h)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Clears all pixels on the canvas in the given rectangle to transparent black.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . fillRect(x, y, w, h)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Paints the given rectangle onto the canvas, using the current fill style.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . strokeRect(x, y, w, h)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Paints the box that outlines the given rectangle onto the canvas, using the current stroke style.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The clearRect(x, y, w, h) method must clear the pixels in the + specified rectangle that also intersect the current clipping region + to a fully transparent black, erasing any previous image. If either + height or width are zero, this method has no effect.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The fillRect(x, y, w, h) method must paint the specified + rectangular area using the fillStyle. If either height + or width are zero, this method has no effect.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The strokeRect(x, y, w, h) method must stroke the specified + rectangle's path using the strokeStyle, lineWidth, lineJoin, and (if + appropriate) miterLimit attributes. If + both height and width are zero, this method has no effect, since + there is no path to stroke (it's a point). If only one of the two is + zero, then the method will draw a line instead (the path for the + outline is just a straight line along the non-zero dimension).

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4.8.11.1.8 Complex shapes (paths)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The context always has a current path. There is only one current + path, it is not part of the drawing state.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              A path has a list of zero or more subpaths. Each + subpath consists of a list of one or more points, connected by + straight or curved lines, and a flag indicating whether the subpath + is closed or not. A closed subpath is one where the last point of + the subpath is connected to the first point of the subpath by a + straight line. Subpaths with fewer than two points are ignored when + painting the path.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . beginPath()
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Resets the current path.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . moveTo(x, y)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Creates a new subpath with the given point.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . closePath()
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Marks the current subpath as closed, and starts a new subpath with a point the same as the start and end of the newly closed subpath.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . lineTo(x, y)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Adds the given point to the current subpath, connected to the previous one by a straight line.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . quadraticCurveTo(cpx, cpy, x, y)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Adds the given point to the current subpath, connected to the previous one by a quadratic Bézier curve with the given control point.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . bezierCurveTo(cp1x, cp1y, cp2x, cp2y, x, y)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Adds the given point to the current subpath, connected to the previous one by a cubic Bézier curve with the given control points.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . arcTo(x1, y1, x2, y2, radius)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Adds an arc with the given control points and radius to the + current subpath, connected to the previous point by a straight + line.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Throws an INDEX_SIZE_ERR exception if the given + radius is negative.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . arc(x, y, radius, startAngle, endAngle [, anticlockwise ] )
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Adds points to the subpath such that the arc described by the + circumference of the circle described by the arguments, starting + at the given start angle and ending at the given end angle, going + in the given direction (defaulting to clockwise), is added to the + path, connected to the previous point by a straight line.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Throws an INDEX_SIZE_ERR exception if the given + radius is negative.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . rect(x, y, w, h)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Adds a new closed subpath to the path, representing the given rectangle.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . fill()
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Fills the subpaths with the current fill style.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . stroke()
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Strokes the subpaths with the current stroke style.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . drawSystemFocusRing(element)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If the given element is focused, draws a focus ring around the + current path, following the platform conventions for focus + rings.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              shouldDraw = context . drawCustomFocusRing(element)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If the given element is focused, and the user has configured + his system to draw focus rings in a particular manner (for + example, high contrast focus rings), draws a focus ring around the + current path and returns false.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Otherwise, returns true if the given element is focused, and + false otherwise. This can thus be used to determine when to draw a + focus ring (see the + example below).

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . scrollPathIntoView()
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Scrolls the current path into view. This is especially useful + on devices with small screens, where the whole canvas might not be + visible at once.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . clip()
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Further constrains the clipping region to the given path.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . isPointInPath(x, y)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns true if the given point is in the current path.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Initially, the context's path must have zero subpaths.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The points and lines added to the path by these methods must be + transformed according to the current transformation + matrix as they are added.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The beginPath() + method must empty the list of subpaths so that the context once + again has zero subpaths.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The moveTo(x, y) method must + create a new subpath with the specified point as its first (and + only) point.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When the user agent is to ensure there is a subpath + for a coordinate (x, y), the + user agent must check to see if the context has any subpaths, and if + it does not, then the user agent must create a new subpath with the + point (x, y) as its first + (and only) point, as if the moveTo() method had been + called.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The closePath() + method must do nothing if the context has no subpaths. Otherwise, it + must mark the last subpath as closed, create a new subpath whose + first point is the same as the previous subpath's first point, and + finally add this new subpath to the path.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If the last subpath had more than one point in its + list of points, then this is equivalent to adding a straight line + connecting the last point back to the first point, thus "closing" + the shape, and then repeating the last (possibly implied) moveTo() call.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              New points and the lines connecting them are added to subpaths + using the methods described below. In all cases, the methods only + modify the last subpath in the context's paths.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The lineTo(x, y) method must + ensure there is a subpath for (x, y) if the context has + no subpaths. Otherwise, it must connect the last point in the + subpath to the given point (x, y) using a straight line, and must then add the given + point (x, y) to the + subpath.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The quadraticCurveTo(cpx, cpy, x, + y) method must ensure there + is a subpath for (cpx, + cpy), and then must connect the last + point in the subpath to the given point (x, y) using a quadratic Bézier curve with control + point (cpx, cpy), and must + then add the given point (x, y) to the subpath. [BEZIER]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The bezierCurveTo(cp1x, cp1y, cp2x, cp2y, x, y) method must + ensure there is a subpath for (cp1x, cp1y), and then must + connect the last point in the subpath to the given point (x, y) using a cubic Bézier + curve with control points (cp1x, cp1y) and (cp2x, cp2y). Then, it must add the point (x, y) to the subpath. [BEZIER]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The arcTo(x1, y1, x2, + y2, radius) + method must first ensure there is a subpath for (x1, y1). Then, the behavior depends on the + arguments and the last point in the subpath, as described below.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Negative values for radius must cause the + implementation to raise an INDEX_SIZE_ERR + exception.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Let the point (x0, y0) be + the last point in the subpath.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If the point (x0, y0) is + equal to the point (x1, y1), + or if the point (x1, y1) is + equal to the point (x2, y2), + or if the radius radius is zero, then the method + must add the point (x1, y1) + to the subpath, and connect that point to the previous point (x0, y0) by a straight line.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Otherwise, if the points (x0, y0), (x1, y1), and (x2, y2) all lie on a single straight line, then the + method must add the point (x1, y1) to the subpath, and connect that point to the + previous point (x0, y0) by a + straight line.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Otherwise, let The Arc be the shortest arc + given by circumference of the circle that has radius radius, and that has one point tangent to the + half-infinite line that crosses the point (x0, + y0) and ends at the point (x1, y1), and that has a different + point tangent to the half-infinite line that ends at the point (x1, y1) and crosses the point + (x2, y2). The points at + which this circle touches these two lines are called the start and + end tangent points respectively. The method must connect the point + (x0, y0) to the start + tangent point by a straight line, adding the start tangent point to + the subpath, and then must connect the start tangent point to the + end tangent point by The Arc, adding the end + tangent point to the subpath.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The arc(x, y, radius, + startAngle, endAngle, anticlockwise) method draws an arc. If + the context has any subpaths, then the method must add a straight + line from the last point in the subpath to the start point of the + arc. In any case, it must draw the arc between the start point of + the arc and the end point of the arc, and add the start and end + points of the arc to the subpath. The arc and its start and end + points are defined as follows:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Consider a circle that has its origin at (x, + y) and that has radius radius. The points at startAngle + and endAngle along this circle's circumference, + measured in radians clockwise from the positive x-axis, are the + start and end points respectively.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If the anticlockwise argument is omitted or + false and endAngle-startAngle is equal to or greater than , or, if the anticlockwise + argument is true and startAngle-endAngle is + equal to or greater than , then the arc + is the whole circumference of this circle.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Otherwise, the arc is the path along the circumference of this + circle from the start point to the end point, going anti-clockwise + if the anticlockwise argument is true, and + clockwise otherwise. Since the points are on the circle, as opposed + to being simply angles from zero, the arc can never cover an angle + greater than radians. If the two points are the + same, or if the radius is zero, then the arc is defined as being of + zero length in both directions.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Negative values for radius must cause the + implementation to raise an INDEX_SIZE_ERR + exception.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The rect(x, y, w, h) method must create a new subpath + containing just the four points (x, y), (x+w, + y), (x+w, y+h), + (x, y+h), with those four points connected by straight + lines, and must then mark the subpath as closed. It must then create + a new subpath with the point (x, y) as the only point in the subpath.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The fill() + method must fill all the subpaths of the current path, using + fillStyle, and using + the non-zero winding number rule. Open subpaths must be implicitly + closed when being filled (without affecting the actual + subpaths).

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Thus, if two overlapping but otherwise independent + subpaths have opposite windings, they cancel out and result in no + fill. If they have the same winding, that area just gets painted + once.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The stroke() method + must calculate the strokes of all the subpaths of the current path, + using the lineWidth, + lineCap, lineJoin, and (if + appropriate) miterLimit attributes, and + then fill the combined stroke area using the strokeStyle + attribute.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Since the subpaths are all stroked as one, + overlapping parts of the paths in one stroke operation are treated + as if their union was what was painted.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Paths, when filled or stroked, must be painted without affecting + the current path, and must be subject to shadow effects, global alpha, the clipping region, and global composition + operators. (Transformations affect the path when the path is + created, not when it is painted, though the stroke style is + still affected by the transformation during painting.)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Zero-length line segments must be pruned before stroking a + path. Empty subpaths must be ignored.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The drawSystemFocusRing(element) method, when invoked, must run + the following steps:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              1. If element is not focused or is not a + descendant of the element with whose context the method is + associated, then abort these steps.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              3. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If the user has requested the use of particular focus rings + (e.g. high-contrast focus rings), or if the element would have a focus ring drawn around it, + then draw a focus ring of the appropriate style along the path, + following platform conventions, and abort these steps.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Some platforms only draw focus rings around + elements that have been focused from the keyboard, and not those + focused from the mouse. Other platforms simply don't draw focus + rings around some elements at all unless relevant accessibility + features are enabled. This API is intended to follow these + conventions. User agents that implement distinctions based on the + manner in which the element was focused are encouraged to classify + focus driven by the focus() method + based on the kind of user interaction event from which the call + was triggered (if any).

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                The focus ring should not be subject to the shadow effects, the global alpha, or the global composition + operators, but should be subject to the clipping region.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              5. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Optionally, inform the user that the + focus is at the location given by the path. User agents may wait + until the next time the event loop reaches its + "update the rendering" step to optionally inform the user.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              6. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The drawCustomFocusRing(element) method, when invoked, must run + the following steps:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              1. If element is not focused or is not a + descendant of the element with whose context the method is + associated, then return false and abort these steps.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              3. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If the user has requested the use of particular focus rings + (e.g. high-contrast focus rings), then draw a focus ring of the + appropriate style along the path, return false, and abort these + steps.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                The focus ring should not be subject to the shadow effects, the global alpha, or the global composition + operators, but should be subject to the clipping region.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              5. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Optionally, inform the user that the + focus is at the location given by the path. User agents may wait + until the next time the event loop reaches its + "update the rendering" step to optionally inform the user.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              6. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              7. Return true.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              8. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The scrollPathIntoView() + method, when invoked, must run the following steps:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              1. Let notional child be a hypothetical + element that is a rendered child of the canvas element + whose dimensions are exactly the rectangle of the bounding box of + the current path.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              3. Scroll notional child into view with the align to top flag set.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4. Optionally, inform the user that the + caret and/or selection cover the specified + rectangle of the canvas. User agents may wait until the next + time the event loop reaches its "update the rendering" + step to optionally inform the user.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              5. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              "Inform the user", as used in this + section, could mean calling a system accessibility API, which would + notify assistive technologies such as magnification tools. To + properly drive magnification based on a focus change, a system + accessibility API driving a screen magnifier needs the bounds for + the newly focused object. The methods above are intended to enable + this by allowing the user agent to report the bounding box of the + path used to render the focus ring as the bounds of the element element passed as an argument, if that + element is focused, and the bounding box of the area to which the + user agent is scrolling as the bounding box of the current + selection.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The clip() + method must create a new clipping region by calculating + the intersection of the current clipping region and the area + described by the current path, using the non-zero winding number + rule. Open subpaths must be implicitly closed when computing the + clipping region, without affecting the actual subpaths. The new + clipping region replaces the current clipping region.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When the context is initialized, the clipping region must be set + to the rectangle with the top left corner at (0,0) and the width and + height of the coordinate space.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The isPointInPath(x, y) method must + return true if the point given by the x and y coordinates passed to the method, when treated as + coordinates in the canvas coordinate space unaffected by the current + transformation, is inside the current path as determined by the + non-zero winding number rule; and must return false + otherwise. Points on the path itself are considered to be inside the + path. If either of the arguments is infinite or NaN, then the method + must return false.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              This canvas element has a couple of checkboxes. The + path-related commands are highlighted:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              <canvas height=400 width=750>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + <label><input type=checkbox id=showA> Show As</label>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + <label><input type=checkbox id=showB> Show Bs</label>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + <!-- ... -->
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +</canvas>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +<script>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + function drawCheckbox(context, element, x, y, paint) {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.save();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.font = '10px sans-serif';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.textAlign = 'left';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.textBaseline = 'middle';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   var metrics = context.measureText(element.labels[0].textContent);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   if (paint) {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     context.beginPath();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     context.strokeStyle = 'black';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     context.rect(x-5, y-5, 10, 10);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     context.stroke();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     if (element.checked) {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +       context.fillStyle = 'black';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +       context.fill();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     context.fillText(element.labels[0].textContent, x+5, y);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.beginPath();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.rect(x-7, y-7, 12 + metrics.width+2, 14);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   if (paint && context.drawCustomFocusRing(element)) {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     context.strokeStyle = 'silver';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     context.stroke();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.restore();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + function drawBase() { /* ... */ }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + function drawAs() { /* ... */ }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + function drawBs() { /* ... */ }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + function redraw() {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   var canvas = document.getElementsByTagName('canvas')[0];
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   var context = canvas.getContext('2d');
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.clearRect(0, 0, canvas.width, canvas.height);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   drawCheckbox(context, document.getElementById('showA'), 20, 40, true);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   drawCheckbox(context, document.getElementById('showB'), 20, 60, true);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   drawBase();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   if (document.getElementById('showA').checked)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     drawAs();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   if (document.getElementById('showB').checked)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     drawBs();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + function processClick(event) {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   var canvas = document.getElementsByTagName('canvas')[0];
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   var context = canvas.getContext('2d');
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   var x = event.clientX;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   var y = event.clientY;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   while (node) {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     x -= node.offsetLeft - node.scrollLeft;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     y -= node.offsetTop - node.scrollTop;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     node = node.offsetParent;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   drawCheckbox(context, document.getElementById('showA'), 20, 40, false);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   if (context.isPointInPath(x, y))
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     document.getElementById('showA').checked = !(document.getElementById('showA').checked);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   drawCheckbox(context, document.getElementById('showB'), 20, 60, false);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   if (context.isPointInPath(x, y))
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     document.getElementById('showB').checked = !(document.getElementById('showB').checked);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   redraw();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + document.getElementsByTagName('canvas')[0].addEventListener('focus', redraw, true);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + document.getElementsByTagName('canvas')[0].addEventListener('blur', redraw, true);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + document.getElementsByTagName('canvas')[0].addEventListener('change', redraw, true);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + document.getElementsByTagName('canvas')[0].addEventListener('click', processClick, false);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + redraw();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +</script>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4.8.11.1.9 Text
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . font [ = value ]
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns the current font settings.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Can be set, to change the font. The syntax is the same as for + the CSS 'font' property; values that cannot be parsed as CSS font + values are ignored.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Relative keywords and lengths are computed relative to the font + of the canvas element.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . textAlign [ = value ]
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns the current text alignment settings.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Can be set, to change the alignment. The possible values are + start, end, left, right, and center. Other values are ignored. The default is + start.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . textBaseline [ = value ]
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns the current baseline alignment settings.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Can be set, to change the baseline alignment. The possible + values and their meanings are given below. Other values are + ignored. The default is alphabetic.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . fillText(text, x, y [, maxWidth ] )
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . strokeText(text, x, y [, maxWidth ] )
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Fills or strokes (respectively) the given text at the given + position. If a maximum width is provided, the text will be scaled + to fit that width if necessary.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              metrics = context . measureText(text)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns a TextMetrics object with the metrics of the given text in the current font.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              metrics . width
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns the advance width of the text that was passed to the + measureText() + method.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The font IDL + attribute, on setting, must be parsed the same way as the 'font' + property of CSS (but without supporting property-independent style + sheet syntax like 'inherit'), and the resulting font must be + assigned to the context, with the 'line-height' component forced to + 'normal', with the 'font-size' component converted to CSS pixels, + and with system fonts being computed to explicit values. If the new + value is syntactically incorrect (including using + property-independent style sheet syntax like 'inherit' or + 'initial'), then it must be ignored, without assigning a new font + value. [CSS]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Font names must be interpreted in the context of the + canvas element's stylesheets; any fonts embedded using + @font-face must therefore be available once + they are loaded. (If a font is referenced before it is fully loaded, + then it must be treated as if it was an unknown font, falling back + to another as described by the relevant CSS specifications.) [CSSFONTS]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Only vector fonts should be used by the user agent; if a user + agent were to use bitmap fonts then transformations would likely + make the font look very ugly.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              On getting, the font + attribute must return the serialized form of the current font of the context + (with no 'line-height' component). [CSSOM]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              For example, after the following statement:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context.font = 'italic 400 12px/2 Unknown Font, sans-serif';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              ...the expression context.font would + evaluate to the string "italic 12px "Unknown Font", sans-serif". The + "400" font-weight doesn't appear because that is the default + value. The line-height doesn't appear because it is forced to + "normal", the default value.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When the context is created, the font of the context must be set + to 10px sans-serif. When the 'font-size' component is set to lengths + using percentages, 'em' or 'ex' units, or the 'larger' or 'smaller' + keywords, these must be interpreted relative to the computed value + of the 'font-size' property of the corresponding canvas + element at the time that the attribute is set. When the + 'font-weight' component is set to the relative values 'bolder' and + 'lighter', these must be interpreted relative to the computed value + of the 'font-weight' property of the corresponding + canvas element at the time that the attribute is + set. If the computed values are undefined for a particular case + (e.g. because the canvas element is not in a + Document), then the relative keywords must be + interpreted relative to the normal-weight 10px sans-serif + default.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The textAlign IDL + attribute, on getting, must return the current value. On setting, if + the value is one of start, end, left, right, or center, then the + value must be changed to the new value. Otherwise, the new value + must be ignored. When the context is created, the textAlign attribute must + initially have the value start.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The textBaseline + IDL attribute, on getting, must return the current value. On + setting, if the value is one of top, hanging, middle, alphabetic, + ideographic, + or bottom, + then the value must be changed to the new value. Otherwise, the new + value must be ignored. When the context is created, the textBaseline attribute + must initially have the value alphabetic.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The textBaseline + attribute's allowed keywords correspond to alignment points in the + font:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The top of the em square is roughly at the top of the glyphs in a font, the hanging baseline is where some glyphs like आ are anchored, the middle is half-way between the top of the em square and the bottom of the em square, the alphabetic baseline is where characters like Á, ÿ, f, and Ω are anchored, the ideographic baseline is where glyphs like 私 and 達 are anchored, and the bottom of the em square is roughly at the bottom of the glyphs in a font. The top and bottom of the bounding box can be far from these baselines, due to glyphs extending far outside the em square.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The keywords map to these alignment points as follows:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              top +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The top of the em square
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              hanging +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The hanging baseline
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              middle +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The middle of the em square
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              alphabetic +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The alphabetic baseline
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              ideographic +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The ideographic baseline
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              bottom +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The bottom of the em square
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The fillText() and + strokeText() + methods take three or four arguments, text, x, y, and optionally maxWidth, and render the given text at the given (x, y) coordinates ensuring that the text isn't wider + than maxWidth if specified, using the current + font, textAlign, and textBaseline + values. Specifically, when the methods are called, the user agent + must run the following steps:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              1. If maxWidth is present but less than or + equal to zero, return without doing anything; abort these + steps.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              3. Let font be the current font of the + context, as given by the font attribute.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              5. Replace all the space + characters in text with U+0020 SPACE + characters.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              6. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              7. Form a hypothetical infinitely wide CSS line box containing + a single inline box containing the text text, + with all the properties at their initial values except the 'font' + property of the inline box set to font, the + 'direction' property of the inline box set to the + directionality of the canvas element, and the + 'white-space' property set to 'pre'. [CSS]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              8. + + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              9. If the maxWidth argument was specified + and the hypothetical width of the inline box in the hypothetical + line box is greater than maxWidth CSS pixels, + then change font to have a more condensed font + (if one is available or if a reasonably readable one can be + synthesized by applying a horizontal scale factor to the font) or a + smaller font, and return to the previous step.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              10. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              11. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Let the anchor point be a point on the + inline box, determined by the textAlign and textBaseline values, as + follows:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Horizontal position:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If textAlign is left
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If textAlign is start and the directionality of the + canvas element is 'ltr'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If textAlign is end and the directionality of the + canvas element is 'rtl'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Let the anchor point's horizontal + position be the left edge of the inline box.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If textAlign is right
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If textAlign is end and the directionality of the + canvas element is 'ltr'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If textAlign is start and the directionality of the + canvas element is 'rtl'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Let the anchor point's horizontal + position be the right edge of the inline box.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If textAlign is center
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Let the anchor point's horizontal + position be half way between the left and right edges of the + inline box.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Vertical position:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If textBaseline is top
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Let the anchor point's vertical position + be the top of the em box of the first available font of the + inline box.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If textBaseline is hanging
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Let the anchor point's vertical position + be the hanging baseline of the first available font of the inline + box.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If textBaseline is middle
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Let the anchor point's vertical position + be half way between the bottom and the top of the em box of the + first available font of the inline box.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If textBaseline is alphabetic
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Let the anchor point's vertical position + be the alphabetic baseline of the first available font of the inline + box.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If textBaseline is ideographic
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Let the anchor point's vertical position + be the ideographic baseline of the first available font of the inline + box.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If textBaseline is bottom
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Let the anchor point's vertical position + be the bottom of the em box of the first available font of the + inline box.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              12. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              13. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Paint the hypothetical inline box as the shape given by the + text's glyphs, as transformed by the current transformation + matrix, and anchored and sized so that before applying the + current transformation + matrix, the anchor point is at (x, y) and each CSS pixel is + mapped to one coordinate space unit.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                For fillText() + fillStyle must be + applied to the glyphs and strokeStyle must be + ignored. For strokeText() the reverse + holds and strokeStyle must be + applied to the glyph outlines and fillStyle must be + ignored.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Text is painted without affecting the current path, and is + subject to shadow effects, global alpha, the clipping region, and global composition + operators.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              14. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The measureText() + method takes one argument, text. When the method + is invoked, the user agent must replace all the space characters in text with + U+0020 SPACE characters, and then must form a hypothetical + infinitely wide CSS line box containing a single inline box + containing the text text, with all the + properties at their initial values except the 'white-space' property + of the inline element set to 'pre' and the 'font' property of the + inline element set to the current font of the context as given by + the font attribute, and + must then return a new TextMetrics object with its + width attribute set to + the width of that inline box, in CSS pixels. [CSS]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The TextMetrics interface is used for the objects + returned from measureText(). It has one + attribute, width, which is set + by the measureText() + method.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Glyphs rendered using fillText() and strokeText() can spill out + of the box given by the font size (the em square size) and the width + returned by measureText() (the text + width). This version of the specification does not provide a way to + obtain the bounding box dimensions of the text. If the text is to be + rendered and removed, care needs to be taken to replace the entire + area of the canvas that the clipping region covers, not just the box + given by the em square height and measured text width.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + + + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              A future version of the 2D context API may provide a + way to render fragments of documents, rendered using CSS, straight + to the canvas. This would be provided in preference to a dedicated + way of doing multiline layout.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4.8.11.1.10 Images
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              To draw images onto the canvas, the drawImage method + can be used.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              This method can be invoked with three different sets of arguments:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • drawImage(image, dx, dy) +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • drawImage(image, dx, dy, dw, dh) +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • drawImage(image, sx, sy, sw, sh, dx, dy, dw, dh) +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Each of those three can take either an + HTMLImageElement, an HTMLCanvasElement, or + an HTMLVideoElement for the image + argument.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . drawImage(image, dx, dy)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . drawImage(image, dx, dy, dw, dh)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . drawImage(image, sx, sy, sw, sh, dx, dy, dw, dh)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Draws the given image onto the canvas. The arguments are + interpreted as follows:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The sx and sy parameters give the x and y coordinates of the source rectangle; the sw and sh arguments give the width and height of the source rectangle; the dx and dy give the x and y coordinates of the destination rectangle; and the dw and dh arguments give the width and height of the destination rectangle.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If the first argument isn't an img, + canvas, or video element, throws a + TYPE_MISMATCH_ERR exception. If the image has no + image data, throws an INVALID_STATE_ERR exception. If + the one of the source rectangle dimensions is zero, throws an + INDEX_SIZE_ERR exception. If the image isn't yet + fully decoded, then nothing is drawn.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If not specified, the dw and dh arguments must default to the values of sw and sh, interpreted such that + one CSS pixel in the image is treated as one unit in the canvas + coordinate space. If the sx, sy, sw, and sh arguments are omitted, they must default to 0, 0, + the image's intrinsic width in image pixels, and the image's + intrinsic height in image pixels, respectively. If the image has no + intrinsic dimensions, the concrete object size must be used + instead, as determined using the CSS "Concrete + Object Size Resolution" algorithm, with the specified + size having neither a definite width nor height, nor any + additional contraints, the object's intrinsic properties being those + of the image argument, and the default object + size being the size of the canvas element. [CSSIMAGES]

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The image argument is an instance of either + HTMLImageElement, HTMLCanvasElement, or + HTMLVideoElement.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If the image argument is an + HTMLImageElement object that is not fully decodable, or if the image argument is an HTMLVideoElement + object whose readyState + attribute is either HAVE_NOTHING or HAVE_METADATA, then the + implementation must return without drawing anything.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If the image argument is an + HTMLCanvasElement object with either a horizontal + dimension or a vertical dimension equal to zero, then the + implementation must raise an INVALID_STATE_ERR + exception.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The source rectangle is the rectangle whose corners are the four + points (sx, sy), (sx+sw, sy), (sx+sw, sy+sh), (sx, sy+sh).

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If one of the sw or sh + arguments is zero, the implementation must raise an + INDEX_SIZE_ERR exception.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The destination rectangle is the rectangle whose corners are the + four points (dx, dy), + (dx+dw, dy), (dx+dw, dy+dh), (dx, dy+dh).

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When drawImage() is + invoked, the region of the image specified by the source rectangle + must be painted on the region of the canvas specified by the + destination rectangle, after applying the current transformation + matrix to the points of the destination rectangle.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The original image data of the source image must be used, not the + image as it is rendered (e.g. width and height attributes on the source + element have no effect). The image data must be processed in the + original direction, even if the dimensions given are negative.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              This specification does not define the algorithm to + use when scaling the image, if necessary.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When a canvas is drawn onto itself, the drawing + model requires the source to be copied before the image is drawn + back onto the canvas, so it is possible to copy parts of a canvas + onto overlapping parts of itself.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If the original image data is a bitmap image, the value painted + at a point in the destination rectangle is computed by filtering the + original image data. The user agent may use any filtering algorithm + (for example bilinear interpolation or nearest-neighbor). When the + filtering algorithm requires a pixel value from outside the original + image data, it must instead use the value from the nearest edge + pixel. (That is, the filter uses 'clamp-to-edge' behavior.)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When the drawImage() method + is passed an animated image as its image + argument, the user agent must use the poster frame of the animation, + or, if there is no poster frame, the first frame of the + animation.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When the image argument is an + HTMLVideoElement, then the frame at the current + playback position must be used as the source image, and the + source image's dimensions must be the intrinsic width and + intrinsic height + of the media resource (i.e. after any aspect-ratio + correction has been applied).

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Images are painted without affecting the current path, and are + subject to shadow effects, global alpha, the clipping region, and global composition + operators.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4.8.11.1.11 Pixel manipulation
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              imagedata = context . createImageData(sw, sh)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns an ImageData object with the given + dimensions in CSS pixels (which might map to a different number of + actual device pixels exposed by the object itself). All the pixels + in the returned object are transparent black.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              imagedata = context . createImageData(imagedata)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns an ImageData object with the same + dimensions as the argument. All the pixels in the returned object + are transparent black.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              imagedata = context . getImageData(sx, sy, sw, sh)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns an ImageData object containing the image + data for the given rectangle of the canvas.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Throws a NOT_SUPPORTED_ERR exception if any of the + arguments are not finite. Throws an INDEX_SIZE_ERR + exception if the either of the width or height arguments are + zero.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              imagedata . width
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              imagedata . height
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns the actual dimensions of the data in the ImageData object, in device pixels.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              imagedata . data
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Returns the one-dimensional array containing the data in RGBA order, as integers in the range 0 to 255.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context . putImageData(imagedata, dx, dy [, dirtyX, dirtyY, dirtyWidth, dirtyHeight ])
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Paints the data from the given ImageData object + onto the canvas. If a dirty rectangle is provided, only the pixels + from that rectangle are painted.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The globalAlpha + and globalCompositeOperation + attributes, as well as the shadow attributes, are ignored for the + purposes of this method call; pixels in the canvas are replaced + wholesale, with no composition, alpha blending, no shadows, + etc.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If the first argument is null, throws a + TYPE_MISMATCH_ERR exception. Throws a + NOT_SUPPORTED_ERR exception if any of the other + arguments are not finite.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The createImageData() + method is used to instantiate new blank ImageData + objects. When the method is invoked with two arguments sw and sh, it must return an + ImageData object representing a rectangle with a width + in CSS pixels equal to the absolute magnitude of sw and a height in CSS pixels equal to the absolute + magnitude of sh. When invoked with a single imagedata argument, it must return an + ImageData object representing a rectangle with the same + dimensions as the ImageData object passed as the + argument. The ImageData object returned must be filled + with transparent black.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The getImageData(sx, sy, sw, + sh) method must return an + ImageData object representing the underlying pixel data + for the area of the canvas denoted by the rectangle whose corners are + the four points (sx, sy), + (sx+sw, sy), (sx+sw, sy+sh), (sx, sy+sh), in canvas + coordinate space units. Pixels outside the canvas must be returned + as transparent black. Pixels must be returned as non-premultiplied + alpha values.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If any of the arguments to createImageData() or + getImageData() + are infinite or NaN, the method must instead raise a + NOT_SUPPORTED_ERR exception. If either the sw or sh arguments are zero, + the method must instead raise an INDEX_SIZE_ERR + exception.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              ImageData objects must be initialized so that their + width attribute + is set to w, the number of physical device + pixels per row in the image data, their height attribute is + set to h, the number of rows in the image data, + and their data + attribute is initialized to a CanvasPixelArray object + holding the image data. At least one pixel's worth of image data + must be returned.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The CanvasPixelArray object provides ordered, + indexed access to the color components of each pixel of the image + data. The data must be represented in left-to-right order, row by + row top to bottom, starting with the top left, with each pixel's + red, green, blue, and alpha components being given in that order for + each pixel. Each component of each device pixel represented in this + array must be in the range 0..255, representing the 8 bit value for + that component. The components must be assigned consecutive indices + starting with 0 for the top left pixel's red component.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The CanvasPixelArray object thus represents h×w×4 integers. The + length + attribute of a CanvasPixelArray object must return this + number.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The object's supported property indices are the + numbers in the range 0 .. h×w×4-1.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              To determine the value of + an indexed property index, the user agent + must return the value of the indexth component + in the array.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              To set the value of an + existing indexed property index to value + value, the value of the indexth component in the array must be set to value.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The width and height (w and h) might be different from the sw + and sh arguments to the above methods, e.g. if + the canvas is backed by a high-resolution bitmap, or if the sw and sh arguments are + negative.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The putImageData(imagedata, dx, dy, dirtyX, dirtyY, dirtyWidth, dirtyHeight) method writes data from + ImageData structures back to the canvas.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              If any of the arguments to the method are infinite or NaN, the + method must raise a NOT_SUPPORTED_ERR exception.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When the last four arguments are omitted, they must be assumed to + have the values 0, 0, the width member of the imagedata structure, and the height member of the imagedata structure, respectively.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When invoked with arguments that do not, per the last few + paragraphs, cause an exception to be raised, the putImageData() method + must act as follows:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              1. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Let dxdevice be the x-coordinate + of the device pixel in the underlying pixel data of the canvas + corresponding to the dx coordinate in the + canvas coordinate space.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Let dydevice be the y-coordinate + of the device pixel in the underlying pixel data of the canvas + corresponding to the dy coordinate in the + canvas coordinate space.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              3. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If dirtyWidth is negative, let dirtyX be dirtyX+dirtyWidth, and let dirtyWidth be equal to the absolute magnitude of + dirtyWidth.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If dirtyHeight is negative, let dirtyY be dirtyY+dirtyHeight, and let dirtyHeight be equal to the absolute magnitude of + dirtyHeight.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              5. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If dirtyX is negative, let dirtyWidth be dirtyWidth+dirtyX, and + let dirtyX be zero.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If dirtyY is negative, let dirtyHeight be dirtyHeight+dirtyY, and + let dirtyY be zero.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              6. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              7. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If dirtyX+dirtyWidth is greater than the width attribute of the imagedata argument, let dirtyWidth be the value of that width attribute, minus the + value of dirtyX.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If dirtyY+dirtyHeight is greater than the height attribute of the imagedata argument, let dirtyHeight be the value of that height attribute, minus the + value of dirtyY.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              8. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              9. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                If, after those changes, either dirtyWidth + or dirtyHeight is negative or zero, stop these + steps without affecting the canvas.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              10. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              11. Otherwise, for all integer values of x + and y where dirtyX ≤ x < dirtyX+dirtyWidth + and dirtyY ≤ y < dirtyY+dirtyHeight, copy the four channels of + the pixel with coordinate (x, y) in the imagedata data + structure to the pixel with coordinate (dxdevice+x, + dydevice+y) in the underlying pixel data of the + canvas.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              12. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The handling of pixel rounding when the specified coordinates do + not exactly map to the device coordinate space is not defined by + this specification, except that the following must result in no + visible changes to the rendering:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context.putImageData(context.getImageData(x, y, w, h), p, q);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              ...for any value of x, y, + w, and h and where p is the smaller of x and the sum + of x and w, and q is the smaller of y and the sum + of y and h; and except that + the following two calls:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              context.createImageData(w, h);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +context.getImageData(0, 0, w, h);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              ...must return ImageData objects with the same + dimensions, for any value of w and h. In other words, while user agents may round the + arguments of these methods so that they map to device pixel + boundaries, any rounding performed must be performed consistently + for all of the createImageData(), getImageData() and putImageData() + operations.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Due to the lossy nature of converting to and from + premultiplied alpha color values, pixels that have just been set + using putImageData() might be + returned to an equivalent getImageData() as + different values.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The current path, transformation matrix, + shadow attributes, global alpha, the clipping region, and global composition + operator must not affect the getImageData() and putImageData() + methods.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The data returned by getImageData() is at the + resolution of the canvas backing store, which is likely to not be + one device pixel to each CSS pixel if the display used is a high + resolution display.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              In the following example, the script generates an + ImageData object so that it can draw onto it.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              // canvas is a reference to a <canvas> element
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +var context = canvas.getContext('2d');
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +// create a blank slate
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +var data = context.createImageData(canvas.width, canvas.height);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +// create some plasma
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +FillPlasma(data, 'green'); // green plasma
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +// add a cloud to the plasma
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +AddCloud(data, data.width/2, data.height/2); // put a cloud in the middle
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +// paint the plasma+cloud on the canvas
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +context.putImageData(data, 0, 0);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +// support methods
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +function FillPlasma(data, color) { ... }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +function AddCloud(data, x, y) { ... }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Here is an example of using getImageData() and putImageData() to + implement an edge detection filter.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              <!DOCTYPE HTML>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +<html>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + <head>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  <title>Edge detection demo</title>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  <script>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   var image = new Image();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   function init() {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     image.onload = demo;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     image.src = "image.jpeg";
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   function demo() {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     var canvas = document.getElementsByTagName('canvas')[0];
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     var context = canvas.getContext('2d');
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     // draw the image onto the canvas
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     context.drawImage(image, 0, 0);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     // get the image data to manipulate
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     var input = context.getImageData(0, 0, canvas.width, canvas.height);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     // get an empty slate to put the data into
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     var output = context.createImageData(canvas.width, canvas.height);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     // alias some variables for convenience
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     // notice that we are using input.width and input.height here
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     // as they might not be the same as canvas.width and canvas.height
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     // (in particular, they might be different on high-res displays)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     var w = input.width, h = input.height;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     var inputData = input.data;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     var outputData = output.data;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     // edge detection
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     for (var y = 1; y < h-1; y += 1) {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +       for (var x = 1; x < w-1; x += 1) {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +         for (var c = 0; c < 3; c += 1) {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +           var i = (y*w + x)*4 + c;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +           outputData[i] = 127 + -inputData[i - w*4 - 4] -   inputData[i - w*4] - inputData[i - w*4 + 4] +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +                                 -inputData[i - 4]       + 8*inputData[i]       - inputData[i + 4] +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +                                 -inputData[i + w*4 - 4] -   inputData[i + w*4] - inputData[i + w*4 + 4];
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +         }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +         outputData[(y*w + x)*4 + 3] = 255; // alpha
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +       }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     // put the image data back after manipulation
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +     context.putImageData(output, 0, 0);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  </script>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + </head>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + <body onload="init()">
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +  <canvas></canvas>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + </body>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +</html>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4.8.11.1.12 Drawing model
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When a shape or image is painted, user agents must follow these + steps, in the order given (or act as if they do):

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              1. Render the shape or image onto an infinite transparent black + bitmap, creating image A, as described in the + previous sections. For shapes, the current fill, stroke, and line + styles must be honored, and the stroke must itself also be + subjected to the current transformation matrix.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              3. When shadows are drawn, render the shadow from + image A, using the current shadow styles, + creating image B.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              5. When shadows are drawn, multiply the alpha + component of every pixel in B by globalAlpha.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              6. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              7. When shadows are drawn, composite B within the clipping region over the + current canvas bitmap using the current composition + operator.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              8. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              9. Multiply the alpha component of every pixel in A by globalAlpha.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              10. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              11. Composite A within the clipping + region over the current canvas bitmap using the current + composition operator.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              12. + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4.8.11.1.13 Best practices
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              This section is non-normative.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              When a canvas is interactive, authors should include focusable + elements in the element's fallback content corresponding to each + focusable part of the canvas, as in the example above.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              To indicate which focusable part of the canvas is currently + focused, authors should use the drawSystemFocusRing() + method, passing it the element for which a ring is being drawn. This + method only draws the focus ring if the element is focused, so that + it can simply be called whenever drawing the element, without + checking whether the element is focused or not first.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Authors should avoid implementing text editing controls using the + canvas element. Doing so has a large number of + disadvantages:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • Mouse placement of the caret has to be reimplemented.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • Keyboard movement of the caret has to be reimplemented (possibly across lines, for multiline text input).
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • Scrolling of the text field has to be implemented (horizontally for long lines, vertically for multiline input).
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • Native features such as copy-and-paste have to be reimplemented.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • Native features such as spell-checking have to be reimplemented.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • Native features such as drag-and-drop have to be reimplemented.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • Native features such as page-wide text search have to be reimplemented.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • Native features specific to the user, for example custom text + services, have to be reimplemented. This is close to impossible + since each user might have different services installed, and there + is an unbounded set of possible such services.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • Bidirectional text editing has to be reimplemented.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • For multiline text editing, line wrapping has to be implemented for all relevant languages.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • Text selection has to be reimplemented.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • Dragging of bidirectional text selections has to be reimplemented.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • Platform-native keyboard shortcuts have to be reimplemented.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • Platform-native input method editors (IMEs) have to be reimplemented.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • Undo and redo functionality has to be reimplemented.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • Accessibility features such as magnification following the + caret or selection have to be reimplemented.
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              This is a huge amount of work, and authors are most strongly + encouraged to avoid doing any of it by instead using the + input element, the textarea element, or + the contenteditable + attribute.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4.8.11.1.14 Examples
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              This section is non-normative.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Here is an example of a script that uses canvas to draw pretty glowing lines.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              <canvas width="800" height="450"></canvas>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +<script>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + var context = document.getElementsByTagName('canvas')[0].getContext('2d');
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + var lastX = context.canvas.width * Math.random();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + var lastY = context.canvas.height * Math.random();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + var hue = 0;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + function line() {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.save();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.translate(context.canvas.width/2, context.canvas.height/2);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.scale(0.9, 0.9);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.translate(-context.canvas.width/2, -context.canvas.height/2);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.beginPath();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.lineWidth = 5 + Math.random() * 10;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.moveTo(lastX, lastY);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   lastX = context.canvas.width * Math.random();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   lastY = context.canvas.height * Math.random();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.bezierCurveTo(context.canvas.width * Math.random(),
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +                         context.canvas.height * Math.random(),
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +                         context.canvas.width * Math.random(),
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +                         context.canvas.height * Math.random(),
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +                         lastX, lastY);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   hue = hue + 10 * Math.random();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.strokeStyle = 'hsl(' + hue + ', 50%, 50%)';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.shadowColor = 'white';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.shadowBlur = 10;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.stroke();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.restore();
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + setInterval(line, 50);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + function blank() {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.fillStyle = 'rgba(0,0,0,0.1)';
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +   context.fillRect(0, 0, context.canvas.width, context.canvas.height);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + setInterval(blank, 40);
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +</script>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4.8.11.2 Color spaces and color correction
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The canvas APIs must perform color correction at + only two points: when rendering images with their own gamma + correction and color space information onto the canvas, to convert + the image to the color space used by the canvas (e.g. using the 2D + Context's drawImage() + method with an HTMLImageElement object), and when + rendering the actual canvas bitmap to the output device.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Thus, in the 2D context, colors used to draw shapes + onto the canvas will exactly match colors obtained through the getImageData() + method.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The toDataURL() method + must not include color space information in the resource + returned. Where the output format allows it, the color of pixels in + resources created by toDataURL() must match those + returned by the getImageData() + method.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              In user agents that support CSS, the color space used by a + canvas element must match the color space used for + processing any colors for that element in CSS.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              The gamma correction and color space information of images must + be handled in such a way that an image rendered directly using an + img element would use the same colors as one painted on + a canvas element that is then itself + rendered. Furthermore, the rendering of images that have no color + correction information (such as those returned by the toDataURL() method) must be + rendered with no color correction.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Thus, in the 2D context, calling the drawImage() method to render + the output of the toDataURL() method to the + canvas, given the appropriate dimensions, has no visible effect.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              4.8.11.3 Security with canvas elements
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Information leakage can occur if scripts from + one origin can access information (e.g. read pixels) + from images from another origin (one that isn't the same).

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              To mitigate this, canvas elements are defined to + have a flag indicating whether they are origin-clean. All + canvas elements must start with their + origin-clean set to true. The flag must be set to false if + any of the following actions occur:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Whenever the toDataURL() method of a + canvas element whose origin-clean flag is set to + false is called, the method must raise a SECURITY_ERR + exception.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Whenever the getImageData() method of + the 2D context of a canvas element whose + origin-clean flag is set to false is called with otherwise + correct arguments, the method must raise a SECURITY_ERR + exception.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Whenever the measureText() method of + the 2D context of a canvas element ends up using a font + that has an origin that is not the same as that of the Document object that + owns the canvas element, the method must raise a + SECURITY_ERR exception.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Even resetting the canvas state by changing its + width or height attributes doesn't reset + the origin-clean flag.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + + + diff --git a/testing/web-platform/tests/2dcontext/tools/gentest.py b/testing/web-platform/tests/2dcontext/tools/gentest.py new file mode 100644 index 000000000..079f476d2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/tools/gentest.py @@ -0,0 +1,787 @@ +# Copyright (c) 2010 Philip Taylor +# Released under the BSD license and W3C Test Suite License: see LICENSE.txt + +# Current code status: +# +# This was originally written for use at +# http://philip.html5.org/tests/canvas/suite/tests/ +# +# It has been adapted for use with the Web Platform Test Suite suite at +# https://github.com/w3c/web-platform-tests/ +# +# The W3C version excludes a number of features (multiple versions of each test +# case of varying verbosity, Mozilla mochitests, semi-automated test harness) +# to focus on simply providing reviewable test cases. It also expects a different +# directory structure. +# This code attempts to support both versions, but the non-W3C version hasn't +# been tested recently and is probably broken. + +# To update or add test cases: +# +# * Modify the tests*.yaml files. +# 'name' is an arbitrary hierarchical name to help categorise tests. +# 'desc' is a rough description of what behaviour the test aims to test. +# 'testing' is a list of references to spec.yaml, to show which spec sentences +# this test case is primarily testing. +# 'code' is JavaScript code to execute, with some special commands starting with '@' +# 'expected' is what the final canvas output should be: a string 'green' or 'clear' +# (100x50 images in both cases), or a string 'size 100 50' (or any other size) +# followed by Python code using Pycairo to generate the image. +# +# * Run "python gentest.py". +# This requires a few Python modules which might not be ubiquitous. +# It has only been tested on Linux. +# It will usually emit some warnings, which ideally should be fixed but can +# generally be safely ignored. +# +# * Test the tests, add new ones to Git, remove deleted ones from Git, etc. + +import re +import codecs +import time +import os +import shutil +import sys +import xml.dom.minidom +from xml.dom.minidom import Node + +import cairo + +try: + import syck as yaml # compatible and lots faster +except ImportError: + import yaml + +# Default mode is for the W3C test suite; the --standalone option +# generates various extra files that aren't needed there +W3CMODE = True +if '--standalone' in sys.argv: + W3CMODE = False + +TESTOUTPUTDIR = '../../2dcontext' +IMAGEOUTPUTDIR = '../../2dcontext' +MISCOUTPUTDIR = './output' +SPECOUTPUTDIR = '../../annotated-spec' + +SPECOUTPUTPATH = '../annotated-spec' # relative to TESTOUTPUTDIR + +def simpleEscapeJS(str): + return str.replace('\\', '\\\\').replace('"', '\\"') + +def escapeJS(str): + str = simpleEscapeJS(str) + str = re.sub(r'\[(\w+)\]', r'[\\""+(\1)+"\\"]', str) # kind of an ugly hack, for nicer failure-message output + return str + +def escapeHTML(str): + return str.replace('&', '&').replace('<', '<').replace('>', '>').replace('"', '"') + +def expand_nonfinite(method, argstr, tail): + """ + >>> print expand_nonfinite('f', '<0 a>, <0 b>', ';') + f(a, 0); + f(0, b); + f(a, b); + >>> print expand_nonfinite('f', '<0 a>, <0 b c>, <0 d>', ';') + f(a, 0, 0); + f(0, b, 0); + f(0, c, 0); + f(0, 0, d); + f(a, b, 0); + f(a, b, d); + f(a, 0, d); + f(0, b, d); + """ + # argstr is ", ..." (where usually + # 'invalid' is Infinity/-Infinity/NaN) + args = [] + for arg in argstr.split(', '): + a = re.match('<(.*)>', arg).group(1) + args.append(a.split(' ')) + calls = [] + # Start with the valid argument list + call = [ args[j][0] for j in range(len(args)) ] + # For each argument alone, try setting it to all its invalid values: + for i in range(len(args)): + for a in args[i][1:]: + c2 = call[:] + c2[i] = a + calls.append(c2) + # For all combinations of >= 2 arguments, try setting them to their + # first invalid values. (Don't do all invalid values, because the + # number of combinations explodes.) + def f(c, start, depth): + for i in range(start, len(args)): + if len(args[i]) > 1: + a = args[i][1] + c2 = c[:] + c2[i] = a + if depth > 0: calls.append(c2) + f(c2, i+1, depth+1) + f(call, 0, 0) + + return '\n'.join('%s(%s)%s' % (method, ', '.join(c), tail) for c in calls) + +# Run with --test argument to run unit tests +if len(sys.argv) > 1 and sys.argv[1] == '--test': + import doctest + doctest.testmod() + sys.exit() + +templates = yaml.load(open('templates.yaml', "r").read()) +name_mapping = yaml.load(open('name2dir.yaml', "r").read()) + +spec_assertions = [] +for s in yaml.load(open('spec.yaml', "r").read())['assertions']: + if 'meta' in s: + eval(compile(s['meta'], '', 'exec'), {}, {'assertions':spec_assertions}) + else: + spec_assertions.append(s) + +tests = [] +for t in sum([ yaml.load(open(f, "r").read()) for f in ['tests.yaml', 'tests2d.yaml', 'tests2dtext.yaml']], []): + if 'DISABLED' in t: + continue + if 'meta' in t: + eval(compile(t['meta'], '', 'exec'), {}, {'tests':tests}) + else: + tests.append(t) + +category_names = [] +category_contents_direct = {} +category_contents_all = {} + +spec_ids = {} +for t in spec_assertions: spec_ids[t['id']] = True +spec_refs = {} + +def backref_html(name): + backrefs = [] + c = '' + for p in name.split('.')[:-1]: + c += '.'+p + backrefs.append('%s.' % (c, p)) + backrefs.append(name.split('.')[-1]) + return ''.join(backrefs) + +def make_flat_image(filename, w, h, r,g,b,a): + if os.path.exists('%s/%s' % (IMAGEOUTPUTDIR, filename)): + return filename + surface = cairo.ImageSurface(cairo.FORMAT_ARGB32, w, h) + cr = cairo.Context(surface) + cr.set_source_rgba(r, g, b, a) + cr.rectangle(0, 0, w, h) + cr.fill() + surface.write_to_png('%s/%s' % (IMAGEOUTPUTDIR, filename)) + return filename + +# Ensure the test output directories exist +testdirs = [TESTOUTPUTDIR, IMAGEOUTPUTDIR, MISCOUTPUTDIR] +if not W3CMODE: testdirs.append('%s/mochitests' % MISCOUTPUTDIR) +else: + for map_dir in set(name_mapping.values()): + testdirs.append("%s/%s" % (TESTOUTPUTDIR, map_dir)) +for d in testdirs: + try: os.mkdir(d) + except: pass # ignore if it already exists + +mochitests = [] +used_images = {} + +def expand_test_code(code): + code = re.sub(r'@nonfinite ([^(]+)\(([^)]+)\)(.*)', lambda m: expand_nonfinite(m.group(1), m.group(2), m.group(3)), code) # must come before '@assert throws' + + code = re.sub(r'@assert pixel (\d+,\d+) == (\d+,\d+,\d+,\d+);', + r'_assertPixel(canvas, \1, \2, "\1", "\2");', + code) + + code = re.sub(r'@assert pixel (\d+,\d+) ==~ (\d+,\d+,\d+,\d+);', + r'_assertPixelApprox(canvas, \1, \2, "\1", "\2", 2);', + code) + + code = re.sub(r'@assert pixel (\d+,\d+) ==~ (\d+,\d+,\d+,\d+) \+/- (\d+);', + r'_assertPixelApprox(canvas, \1, \2, "\1", "\2", \3);', + code) + + code = re.sub(r'@assert throws (\S+_ERR) (.*);', + r'assert_throws("\1", function() { \2; });', + code) + + code = re.sub(r'@assert throws (\S+Error) (.*);', + r'assert_throws(new \1(), function() { \2; });', + code) + + code = re.sub(r'@assert throws (.*);', + r'assert_throws(null, function() { \1; });', + code) + + code = re.sub(r'@assert (.*) === (.*);', + lambda m: '_assertSame(%s, %s, "%s", "%s");' + % (m.group(1), m.group(2), escapeJS(m.group(1)), escapeJS(m.group(2))) + , code) + + code = re.sub(r'@assert (.*) !== (.*);', + lambda m: '_assertDifferent(%s, %s, "%s", "%s");' + % (m.group(1), m.group(2), escapeJS(m.group(1)), escapeJS(m.group(2))) + , code) + + code = re.sub(r'@assert (.*) =~ (.*);', + lambda m: 'assert_regexp_match(%s, %s);' + % (m.group(1), m.group(2)) + , code) + + code = re.sub(r'@assert (.*);', + lambda m: '_assert(%s, "%s");' + % (m.group(1), escapeJS(m.group(1))) + , code) + + code = re.sub(r' @moz-todo', '', code) + + code = re.sub(r'@moz-UniversalBrowserRead;', + "" + , code) + + assert('@' not in code) + + return code + +def expand_mochitest_code(code): + code = re.sub(r'@nonfinite ([^(]+)\(([^)]+)\)(.*)', lambda m: expand_nonfinite(m.group(1), m.group(2), m.group(3)), code) + + code = re.sub(r'@assert pixel (\d+,\d+) == (\d+,\d+,\d+,\d+);', + r'isPixel(ctx, \1, \2, "\1", "\2", 0);', + code) + + code = re.sub(r'@assert pixel (\d+,\d+) ==~ (\d+,\d+,\d+,\d+);', + r'isPixel(ctx, \1, \2, "\1", "\2", 2);', + code) + + code = re.sub(r'@assert pixel (\d+,\d+) ==~ (\d+,\d+,\d+,\d+) \+/- (\d+);', + r'isPixel(ctx, \1, \2, "\1", "\2", \3);', + code) + + code = re.sub(r'@assert throws (\S+_ERR) (.*);', + lambda m: 'var _thrown = undefined; try {\n %s;\n} catch (e) { _thrown = e }; ok(_thrown && _thrown.code == DOMException.%s, "should throw %s");' + % (m.group(2), m.group(1), m.group(1)) + , code) + + code = re.sub(r'@assert throws (\S+Error) (.*);', + lambda m: 'var _thrown = undefined; try {\n %s;\n} catch (e) { _thrown = e }; ok(_thrown && (_thrown instanceof %s), "should throw %s");' + % (m.group(2), m.group(1), m.group(1)) + , code) + + code = re.sub(r'@assert throws (.*);', + lambda m: 'try { var _thrown = false;\n %s;\n} catch (e) { _thrown = true; } finally { ok(_thrown, "should throw exception"); }' + % (m.group(1)) + , code) + + code = re.sub(r'@assert (.*) =~ (.*);', + lambda m: 'ok(%s.match(%s), "%s.match(%s)");' + % (m.group(1), m.group(2), escapeJS(m.group(1)), escapeJS(m.group(2))) + , code) + + code = re.sub(r'@assert (.*);', + lambda m: 'ok(%s, "%s");' + % (m.group(1), escapeJS(m.group(1))) + , code) + + code = re.sub(r'((?:^|\n|;)\s*)ok(.*;) @moz-todo', + lambda m: '%stodo%s' + % (m.group(1), m.group(2)) + , code) + + code = re.sub(r'((?:^|\n|;)\s*)(is.*;) @moz-todo', + lambda m: '%stodo_%s' + % (m.group(1), m.group(2)) + , code) + + code = re.sub(r'@moz-UniversalBrowserRead;', + "netscape.security.PrivilegeManager.enablePrivilege('UniversalBrowserRead');" + , code) + + code = code.replace('../images/', 'image_') + + assert '@' not in code, '@ not in code:\n%s' % code + + return code + +used_tests = {} +for i in range(len(tests)): + test = tests[i] + + name = test['name'] + print "\r(%s)" % name, " "*32, "\t", + + if name in used_tests: + print "Test %s is defined twice" % name + used_tests[name] = 1 + + mapped_name = None + for mn in sorted(name_mapping.keys(), key=len, reverse=True): + if name.startswith(mn): + mapped_name = "%s/%s" % (name_mapping[mn], name) + break + if not mapped_name: + print "LIKELY ERROR: %s has no defined target directory mapping" % name + mapped_name = name + if 'manual' in test: + mapped_name += "-manual" + + cat_total = '' + for cat_part in [''] + name.split('.')[:-1]: + cat_total += cat_part+'.' + if not cat_total in category_names: category_names.append(cat_total) + category_contents_all.setdefault(cat_total, []).append(name) + category_contents_direct.setdefault(cat_total, []).append(name) + + for ref in test.get('testing', []): + if ref not in spec_ids: + print "Test %s uses nonexistent spec point %s" % (name, ref) + spec_refs.setdefault(ref, []).append(name) + #if not (len(test.get('testing', [])) or 'mozilla' in test): + if not test.get('testing', []): + print "Test %s doesn't refer to any spec points" % name + + if test.get('expected', '') == 'green' and re.search(r'@assert pixel .* 0,0,0,0;', test['code']): + print "Probable incorrect pixel test in %s" % name + + code = expand_test_code(test['code']) + + mochitest = not (W3CMODE or 'manual' in test or 'disabled' in test.get('mozilla', {})) + if mochitest: + mochi_code = expand_mochitest_code(test['code']) + + mochi_name = name + if 'mozilla' in test: + if 'throws' in test['mozilla']: + mochi_code = templates['mochitest.exception'] % mochi_code + if 'bug' in test['mozilla']: + mochi_name = "%s - bug %s" % (name, test['mozilla']['bug']) + + if 'desc' in test: + mochi_desc = '\n' % test['desc'] + else: + mochi_desc = '' + + if 'deferTest' in mochi_code: + mochi_setup = '' + mochi_footer = '' + else: + mochi_setup = '' + mochi_footer = 'SimpleTest.finish();\n' + + for f in ['isPixel', 'todo_isPixel', 'deferTest', 'wrapFunction']: + if f in mochi_code: + mochi_setup += templates['mochitest.%s' % f] + else: + if not W3CMODE: + print "Skipping mochitest for %s" % name + mochi_name = '' + mochi_desc = '' + mochi_code = '' + mochi_setup = '' + mochi_footer = '' + + expectation_html = '' + if 'expected' in test and test['expected'] is not None: + expected = test['expected'] + expected_img = None + if expected == 'green': + expected_img = make_flat_image('green-100x50.png', 100, 50, 0,1,0,1) + if W3CMODE: expected_img = "/images/" + expected_img + elif expected == 'clear': + expected_img = make_flat_image('clear-100x50.png', 100, 50, 0,0,0,0) + if W3CMODE: expected_img = "/images/" + expected_img + else: + if ';' in expected: print "Found semicolon in %s" % name + expected = re.sub(r'^size (\d+) (\d+)', + r'surface = cairo.ImageSurface(cairo.FORMAT_ARGB32, \1, \2)\ncr = cairo.Context(surface)', + expected) + + if mapped_name.endswith("-manual"): + png_name = mapped_name[:-len("-manual")] + else: + png_name = mapped_name + expected += "\nsurface.write_to_png('%s/%s.png')\n" % (IMAGEOUTPUTDIR, png_name) + eval(compile(expected, '' % test['name'], 'exec'), {}, {'cairo':cairo}) + expected_img = "%s.png" % name + + if expected_img: + expectation_html = ('

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:' + + '

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              ' % (expected_img)) + + canvas = test.get('canvas', 'width="100" height="50"') + + prev = tests[i-1]['name'] if i != 0 else 'index' + next = tests[i+1]['name'] if i != len(tests)-1 else 'index' + + name_wrapped = name.replace('.', '.​') # (see https://bugzilla.mozilla.org/show_bug.cgi?id=376188) + + refs = ''.join('

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            • %s\n' % (SPECOUTPUTPATH, n,n) for n in test.get('testing', [])) + if not W3CMODE and 'mozilla' in test and 'bug' in test['mozilla']: + refs += '
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            • Bugzilla' % test['mozilla']['bug'] + + notes = '

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              %s' % test['notes'] if 'notes' in test else '' + + scripts = '' + for s in test.get('scripts', []): + scripts += '\n' % (s) + + images = '' + for i in test.get('images', []): + id = i.split('/')[-1] + if '/' not in i: + used_images[i] = 1 + i = '../images/%s' % i + images += '\n' % (i,id) + mochi_images = images.replace('../images/', 'image_') + if W3CMODE: images = images.replace("../images/", "/images/") + + fonts = '' + fonthack = '' + for i in test.get('fonts', []): + fonts += '@font-face {\n font-family: %s;\n src: url("/fonts/%s.ttf");\n}\n' % (i, i) + # Browsers require the font to actually be used in the page + if test.get('fonthack', 1): + fonthack += 'A\n' % i + if fonts: + fonts = '\n' % fonts + + fallback = test.get('fallback', '

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              ') + + desc = test.get('desc', '') + escaped_desc = simpleEscapeJS(desc) + template_params = { + 'name':name, 'name_wrapped':name_wrapped, 'backrefs':backref_html(name), + 'mapped_name':mapped_name, + 'desc':desc, 'escaped_desc':escaped_desc, + 'prev':prev, 'next':next, 'refs':refs, 'notes':notes, 'images':images, + 'fonts':fonts, 'fonthack':fonthack, + 'canvas':canvas, 'expected':expectation_html, 'code':code, 'scripts':scripts, + 'mochi_name':mochi_name, 'mochi_desc':mochi_desc, 'mochi_code':mochi_code, + 'mochi_setup':mochi_setup, 'mochi_footer':mochi_footer, 'mochi_images':mochi_images, + 'fallback':fallback + } + + if W3CMODE: + f = codecs.open('%s/%s.html' % (TESTOUTPUTDIR, mapped_name), 'w', 'utf-8') + f.write(templates['w3c'] % template_params) + else: + f = codecs.open('%s/%s.html' % (TESTOUTPUTDIR, name), 'w', 'utf-8') + f.write(templates['standalone'] % template_params) + + f = codecs.open('%s/framed.%s.html' % (TESTOUTPUTDIR, name), 'w', 'utf-8') + f.write(templates['framed'] % template_params) + + f = codecs.open('%s/minimal.%s.html' % (TESTOUTPUTDIR, name), 'w', 'utf-8') + f.write(templates['minimal'] % template_params) + + if mochitest: + mochitests.append(name) + f = codecs.open('%s/mochitests/test_%s.html' % (MISCOUTPUTDIR, name), 'w', 'utf-8') + f.write(templates['mochitest'] % template_params) + +def write_mochitest_makefile(): + f = open('%s/mochitests/Makefile.in' % MISCOUTPUTDIR, 'w') + f.write(templates['mochitest.Makefile']) + files = ['test_%s.html' % n for n in mochitests] + ['image_%s' % n for n in used_images] + chunksize = 100 + chunks = [] + for i in range(0, len(files), chunksize): + chunk = files[i:i+chunksize] + name = '_TEST_FILES_%d' % (i / chunksize) + chunks.append(name) + f.write('%s = \\\n' % name) + for file in chunk: f.write('\t%s \\\n' % file) + f.write('\t$(NULL)\n\n') + f.write('# split up into groups to work around command-line length limits\n') + for name in chunks: + f.write('libs:: $(%s)\n\t$(INSTALL) $(foreach f,$^,"$f") $(DEPTH)/_tests/testing/mochitest/tests/$(relativesrcdir)\n\n' % name) + +if not W3CMODE: + for i in used_images: + shutil.copyfile("../../images/%s" % i, "%s/mochitests/image_%s" % (MISCOUTPUTDIR, i)) + write_mochitest_makefile() + +print + +def write_index(): + f = open('%s/index.html' % TESTOUTPUTDIR, 'w') + f.write(templates['index.w3c' if W3CMODE else 'index'] % { 'updated':time.strftime('%Y-%m-%d', time.gmtime()) }) + f.write('\n
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                \n') + depth = 1 + for category in category_names: + name = category[1:-1] or '' + count = len(category_contents_all[category]) + new_depth = category.count('.') + while new_depth < depth: f.write(' '*(depth-1) + '
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              \n'); depth -= 1 + f.write(' '*depth + templates['index.w3c.category.item' if W3CMODE else 'index.category.item'] % (name or 'all', name, count, '' if count==1 else 's')) + while new_depth+1 > depth: f.write(' '*depth + '
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                \n'); depth += 1 + for item in category_contents_direct.get(category, []): + f.write(' '*depth + '
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • %s\n' % (item, item) ) + while 0 < depth: f.write(' '*(depth-1) + '
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              \n'); depth -= 1 + +def write_category_indexes(): + for category in category_names: + name = (category[1:-1] or 'all') + + f = open('%s/index.%s.html' % (TESTOUTPUTDIR, name), 'w') + f.write(templates['index.w3c.frame' if W3CMODE else 'index.frame'] % { 'backrefs':backref_html(name), 'category':name }) + for item in category_contents_all[category]: + f.write(templates['index.w3c.frame.item' if W3CMODE else 'index.frame.item'] % item) + +def write_reportgen(): + f = open('%s/reportgen.html' % MISCOUTPUTDIR, 'w') + items_text = ',\n'.join(('"%s"' % item) for item in category_contents_all['.']) + f.write(templates['reportgen'] % {'items':items_text }) + +def write_results(): + results = {} + uas = [] + uastrings = {} + for item in category_contents_all['.']: results[item] = {} + + f = open('%s/results.html' % MISCOUTPUTDIR, 'w') + f.write(templates['results']) + + if not os.path.exists('results.yaml'): + print "Can't find results.yaml" + else: + for resultset in yaml.load(open('results.yaml', "r").read()): + #title = "%s (%s)" % (resultset['ua'], resultset['time']) + title = resultset['name'] + #assert title not in uas # don't allow repetitions + if title not in uas: + uas.append(title) + uastrings[title] = resultset['ua'] + else: + assert uastrings[title] == resultset['ua'] + for r in resultset['results']: + if r['id'] not in results: + print 'Skipping results for removed test %s' % r['id'] + continue + results[r['id']][title] = ( + r['status'].lower(), + re.sub(r'%(..)', lambda m: chr(int(m.group(1), 16)), + re.sub(r'%u(....)', lambda m: unichr(int(m.group(1), 16)), + r['notes'])).encode('utf8') + ) + + passes = {} + for ua in uas: + f.write('%s\n' % (uastrings[ua], ua)) + passes[ua] = 0 + for id in category_contents_all['.']: + f.write('# %s\n' % (id, id, id, id)) + for ua in uas: + status, details = results[id].get(ua, ('', '')) + f.write('
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                %s
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              \n' % (status, details)) + if status == 'pass': passes[ua] += 1 + f.write('Passes\n') + for ua in uas: + f.write('%.1f%%\n' % ((100.0 * passes[ua]) / len(category_contents_all['.']))) + f.write('\n') + for ua in uas: + f.write('%s\n' % ua) + f.write('\n') + +def getNodeText(node): + t, offsets = '', [] + + # Skip over any previous annotations we added + if node.nodeType == node.ELEMENT_NODE and 'testrefs' in node.getAttribute('class').split(' '): + return t, offsets + + if node.nodeType == node.TEXT_NODE: + val = node.nodeValue + val = val.replace(unichr(0xa0), ' ') # replace  s + t += val + offsets += [ (node, len(node.nodeValue)) ] + for n in node.childNodes: + child_t, child_offsets = getNodeText(n) + t += child_t + offsets += child_offsets + return t, offsets + +def htmlSerializer(element): + element.normalize() + rv = [] + specialtext = ['style', 'script', 'xmp', 'iframe', 'noembed', 'noframes', 'noscript'] + empty = ['area', 'base', 'basefont', 'bgsound', 'br', 'col', 'embed', 'frame', + 'hr', 'img', 'input', 'link', 'meta', 'param', 'spacer', 'wbr'] + + def serializeElement(element): + if element.nodeType == Node.DOCUMENT_TYPE_NODE: + rv.append("" % element.name) + elif element.nodeType == Node.DOCUMENT_NODE: + for child in element.childNodes: + serializeElement(child) + elif element.nodeType == Node.COMMENT_NODE: + rv.append("" % element.nodeValue) + elif element.nodeType == Node.TEXT_NODE: + unescaped = False + n = element.parentNode + while n is not None: + if n.nodeName in specialtext: + unescaped = True + break + n = n.parentNode + if unescaped: + rv.append(element.nodeValue) + else: + rv.append(escapeHTML(element.nodeValue)) + else: + rv.append("<%s" % element.nodeName) + if element.hasAttributes(): + for name, value in element.attributes.items(): + rv.append(' %s="%s"' % (name, escapeHTML(value))) + rv.append(">") + if element.nodeName not in empty: + for child in element.childNodes: + serializeElement(child) + rv.append("" % element.nodeName) + serializeElement(element) + return '\n' + ''.join(rv) + +def write_annotated_spec(): + # Load the stripped-down XHTMLised copy of the spec + doc = xml.dom.minidom.parse(open('current-work-canvas.xhtml', 'r')) + + # Insert our new stylesheet + n = doc.getElementsByTagName('head')[0].appendChild(doc.createElement('link')) + n.setAttribute('rel', 'stylesheet') + n.setAttribute('href', '../common/canvas-spec.css' if W3CMODE else '../spectest.css') + n.setAttribute('type', 'text/css') + + spec_assertion_patterns = [] + for a in spec_assertions: + # Warn about problems + if a['id'] not in spec_refs: + print "Unused spec statement %s" % a['id'] + + pattern_text = a['text'] + + if 'keyword' in a: + # Explicit keyword override + keyword = a['keyword'] + else: + # Extract the marked keywords, and remove the markers + keyword = 'none' + for kw in ['must', 'should', 'required']: + if ('*%s*' % kw) in pattern_text: + keyword = kw + pattern_text = pattern_text.replace('*%s*' % kw, kw) + break + # Make sure there wasn't >1 keyword + for kw in ['must', 'should', 'required']: + assert('*%s*' % kw not in pattern_text) + + # Convert the special pattern format into regexp syntax + pattern_text = (pattern_text. + # Escape relevant characters + replace('*', r'\*'). + replace('+', r'\+'). + replace('.', r'\.'). + replace('(', r'\('). + replace(')', r'\)'). + replace('[', r'\['). + replace(']', r'\]'). + # Convert special sequences back into unescaped regexp code + replace(' ', r'\s+'). + replace(r'<\.\.\.>', r'.+'). + replace('<^>', r'()'). + replace('', r'\s*?\n') + ) + pattern = re.compile(pattern_text, re.S) + spec_assertion_patterns.append( (a['id'], pattern, keyword, a.get('previously', None)) ) + matched_assertions = {} + + def process_element(e): + if e.nodeType == e.ELEMENT_NODE and (e.getAttribute('class') == 'impl' or e.hasAttribute('data-component')): + for c in e.childNodes: + process_element(c) + return + + t, offsets = getNodeText(e) + for id, pattern, keyword, previously in spec_assertion_patterns: + m = pattern.search(t) + if m: + # When the pattern-match isn't enough to uniquely identify a sentence, + # allow explicit back-references to earlier paragraphs + if previously: + if len(previously) >= 3: + n, text, exp = previously + else: + n, text = previously + exp = True + node = e + while n and node.previousSibling: + node = node.previousSibling + n -= 1 + if (text not in getNodeText(node)[0]) == exp: + continue # discard this match + + if id in matched_assertions: + print "Spec statement %s matches multiple places" % id + matched_assertions[id] = True + + if m.lastindex != 1: + print "Spec statement %s has incorrect number of match groups" % id + + end = m.end(1) + end_node = None + for end_node, o in offsets: + if end < o: + break + end -= o + assert(end_node) + + n1 = doc.createElement('span') + n1.setAttribute('class', 'testrefs kw-%s' % keyword) + n1.setAttribute('id', 'testrefs.%s' % id) + n1.appendChild(doc.createTextNode(' ')) + + n = n1.appendChild(doc.createElement('a')) + n.setAttribute('href', '#testrefs.%s' % id) + n.setAttribute('title', id) + n.appendChild(doc.createTextNode('#')) + + n1.appendChild(doc.createTextNode(' ')) + for test_id in spec_refs.get(id, []): + n = n1.appendChild(doc.createElement('a')) + n.setAttribute('href', '../canvas/%s.html' % test_id) + n.appendChild(doc.createTextNode(test_id)) + n1.appendChild(doc.createTextNode(' ')) + n0 = doc.createTextNode(end_node.nodeValue[:end]) + n2 = doc.createTextNode(end_node.nodeValue[end:]) + + p = end_node.parentNode + p.replaceChild(n2, end_node) + p.insertBefore(n1, n2) + p.insertBefore(n0, n1) + + t, offsets = getNodeText(e) + + for e in doc.getElementsByTagName('body')[0].childNodes: + process_element(e) + + for s in spec_assertions: + if s['id'] not in matched_assertions: + print "Annotation incomplete: Unmatched spec statement %s" % s['id'] + + # Convert from XHTML back to HTML + doc.documentElement.removeAttribute('xmlns') + doc.documentElement.setAttribute('lang', doc.documentElement.getAttribute('xml:lang')) + + head = doc.documentElement.getElementsByTagName('head')[0] + head.insertBefore(doc.createElement('meta'), head.firstChild).setAttribute('charset', 'UTF-8') + + f = codecs.open('%s/canvas.html' % SPECOUTPUTDIR, 'w', 'utf-8') + f.write(htmlSerializer(doc)) + +if not W3CMODE: + write_index() + write_category_indexes() + write_reportgen() + write_results() + write_annotated_spec() diff --git a/testing/web-platform/tests/2dcontext/tools/name2dir.yaml b/testing/web-platform/tests/2dcontext/tools/name2dir.yaml new file mode 100644 index 000000000..6c170ce55 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/tools/name2dir.yaml @@ -0,0 +1,45 @@ +2d.transformation: "transformations" +2d.composite: "compositing" +2d.coordinatespace: "conformance-requirements" +2d.missingargs: "conformance-requirements" +2d.type.delete: "conformance-requirements" +2d.voidreturn: "conformance-requirements" +2d.drawImage: "drawing-images-to-the-canvas" +2d.clearRect: "drawing-rectangles-to-the-canvas" +2d.fillRect: "drawing-rectangles-to-the-canvas" +2d.strokeRect: "drawing-rectangles-to-the-canvas" +2d.text.draw: "drawing-text-to-the-canvas" +2d.text.draw.baseline.alphabetic: "drawing-text-to-the-canvas" +2d.text.draw.space.basic: "drawing-text-to-the-canvas" +2d.text.draw.space.collapse: "drawing-text-to-the-canvas" +2d.text.measure: "drawing-text-to-the-canvas" +2d.fillStyle: "fill-and-stroke-styles" +2d.gradient: "fill-and-stroke-styles" +2d.pattern: "fill-and-stroke-styles" +2d.strokeStyle: "fill-and-stroke-styles" +2d.line: "line-styles" +2d.path: "path-objects" +2d.imageData: "pixel-manipulation" +2d.shadow: "shadows" +2d.text.align: "text-styles" +2d.text.baseline: "text-styles" +2d.text.font: "text-styles" +2d.text.draw.baseline: "text-styles" +2d.text.draw.space: "text-styles" +2d.text.measure.width.space: "text-styles" +2d.text.draw.space.collapse.end: "text-styles" +2d.text.draw.space.collapse.other: "text-styles" +2d.text.draw.space.collapse.space: "text-styles" +2d.text.draw.space.collapse.start: "text-styles" +2d.state: "the-canvas-state" +2d.canvas: "../html/semantics/embedded-content/the-canvas-element/" +2d.getcontext: "../html/semantics/embedded-content/the-canvas-element/" +2d.scaled: "../html/semantics/embedded-content/the-canvas-element/" +2d.type: "../html/semantics/embedded-content/the-canvas-element/" +context: "../html/semantics/embedded-content/the-canvas-element/" +fallback: "../html/semantics/embedded-content/the-canvas-element/" +initial: "../html/semantics/embedded-content/the-canvas-element/" +security: "../html/semantics/embedded-content/the-canvas-element/" +size: "../html/semantics/embedded-content/the-canvas-element/" +toDataURL: "../html/semantics/embedded-content/the-canvas-element/" +type: "../html/semantics/embedded-content/the-canvas-element/" diff --git a/testing/web-platform/tests/2dcontext/tools/spec.yaml b/testing/web-platform/tests/2dcontext/tools/spec.yaml new file mode 100644 index 000000000..12b7d6be9 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/tools/spec.yaml @@ -0,0 +1,717 @@ +# Extracts from http://www.whatwg.org/specs/web-apps/current-work/ +# +# (c) Copyright 2004-2011 Apple Computer, Inc., Mozilla Foundation, and Opera Software ASA. +# You are granted a license to use, reproduce and create derivative works of this document. + +assertions: + - id: canvas.type + text: "interface HTMLCanvasElement<^> : HTMLElement {" + - id: size.width + text: "interface HTMLCanvasElement<...>attribute unsigned long width;<^>" + - id: size.height + text: "interface HTMLCanvasElement<...>attribute unsigned long height;<^>" + - id: canvas.getContext + text: "interface HTMLCanvasElement<...>object\\? getContext(in DOMString contextId, in any... args);<^>" + - id: fallback + text: "The contents of the canvas element, if any, are the element's fallback content<^>." + - id: size.nonnegativeinteger + text: "The rules for parsing non-negative integers *must* be used to obtain their numeric values<^>." + - id: size.missing + text: "If an attribute is missing<^>, <...> then the default value *must* be used instead." + - id: size.error + text: "if parsing its value returns an error<^>, then the default value *must* be used instead." + - id: size.default + text: "The width attribute defaults to 300, and the height attribute defaults to 150<^>." + - id: size.css + text: "the element can be sized arbitrarily by a style sheet. During rendering, the image is scaled to fit this layout size<^>." + - id: initial.reset + text: "When the canvas element is created, and subsequently whenever the width and height attributes are set (whether to a new value or to the previous value), the bitmap and any associated contexts *must* be cleared back to their initial state <...><^>." + - id: initial.colour + text: "When the canvas is initialized, its bitmap *must* be cleared to transparent black<^>." + - id: size.reflect + text: "The width and height IDL attributes *must* reflect the respective content attributes of the same name<^>," + + - id: context.unrecognised + text: "If contextId is not the name of a context supported by the user agent, return null and abort these steps<^>." + - id: context.unique + text: "If the getContext() method has already been invoked on this element for the same contextId, return the same object as was returned that time, and abort these steps<^>." + - id: context.2d + text: "When the getContext() method of a canvas element is to return a new object for the contextId 2d, the user agent *must* return a new CanvasRenderingContext2D object<^>." + - id: context.2d.extraargs + text: "When the getContext() method of a canvas element is to return a new object for the contextId 2d, the user agent *must* return a new CanvasRenderingContext2D object. Any additional arguments are ignored<^>." + + - id: toDataURL.noarguments + text: "When a user agent is to create a serialization of the image as a file, <...> if there are no arguments, in the PNG format<^>." + - id: toDataURL.zerosize + text: "If the canvas has no pixels (i.e. either its horizontal dimension or its vertical dimension is zero) then return the string \"data:,\"<^> and abort these steps." + - id: toDataURL.witharguments + text: "If arguments is not empty, the first value must be interpreted as a MIME type giving the format to use<^>." + - id: toDataURL.noalpha + text: "For image types that do not support an alpha channel, the serialized image *must* be the canvas image composited onto a solid black background using the source-over operator<^>." + - id: toDataURL.png + text: "User agents *must* support PNG (\"image/png\")<^>." + - id: toDataURL.unrecognised + text: "If the user agent does not support the requested type, it *must* create the file using the PNG format<^>." + - id: toDataURL.lowercase + text: "User agents *must* convert the provided type to ASCII lowercase before establishing if they support that type<^>." + - id: toDataURL.jpeg + previously: [ 0, "image/png", false ] + text: "image/jpeg<^>" + - id: toDataURL.jpeg.quality + text: "The second argument, if it is a number in the range 0.0 to 1.0 inclusive, *must* be treated as the desired quality level<^>." + - id: toDataURL.jpeg.nan + text: "If it is not a number<^> <...>, the user agent *must* use its default value, as if the argument had been omitted." + - id: toDataURL.jpeg.range + text: "If it is <...> outside that range<^>, the user agent *must* use its default value, as if the argument had been omitted." + - id: toDataURL.arguments + text: "Other arguments *must* be ignored and must not cause the user agent to raise an exception<^>." + + - id: 2d.coordinatespace + text: "flat Cartesian surface whose origin (0,0) is at the top left corner, with the coordinate space having x values increasing when going right, and y values increasing when going down<^>." + - id: context.2d.type + text: "interface CanvasRenderingContext2D<^> {" + - id: 2d.canvasGradient.type + text: "interface CanvasGradient<^> {" + - id: 2d.imageData.type + text: "interface ImageData<^> {" + - id: 2d.canvas.attribute + text: "readonly<^> attribute HTMLCanvasElement canvas;" + - id: 2d.canvas + text: "The canvas attribute *must* return the canvas element that the context paints on<^>." + - id: 2d.nonfinite + text: "Except where otherwise specified, for the 2D context interface, any method call with a numeric argument whose value is infinite or a NaN value *must* be ignored<^>." + + - id: 2d.currentColor.onset + text: "Whenever the CSS value currentColor is used as a color in this API, the \"computed value of the 'color' property\" for the purposes of determining the computed value of the currentColor keyword is the computed value of the 'color' property on the element in question at the time that the color is specified<^>" + - id: 2d.currentColor.outofdoc + text: "If the computed value of the 'color' property is undefined for a particular case (e.g. because the element is not in a Document), then the \"computed value of the 'color' property\" for the purposes of determining the computed value of the currentColor keyword is fully opaque black<^>." + - id: 2d.currentColor.gradient + text: "In the case of addColorStop() on CanvasGradient, the \"computed value of the 'color' property\" for the purposes of determining the computed value of the currentColor keyword is always fully opaque black<^> (there is no associated element)." + + - id: 2d.state.transformation + text: "The current transformation matrix<^>." + - id: 2d.state.clip + text: "The current clipping region<^>." + - meta: | + for s in [ + 'strokeStyle', 'fillStyle', 'globalAlpha', + 'lineWidth', 'lineCap', 'lineJoin', 'miterLimit', + 'shadowOffsetX', 'shadowOffsetY', 'shadowBlur', 'shadowColor', + 'globalCompositeOperation', + 'font', 'textAlign', 'textBaseline' + ]: + assertions.append( { + 'id': '2d.state.%s' % s, + 'text': 'The current values of the following attributes:<...>%s<^>' % s + } ) + - id: 2d.state.path + text: "The current path<^> <...> are not part of the drawing state." + - id: 2d.state.bitmap + text: "The <...> current bitmap<^> are not part of the drawing state." + + - id: 2d.state.save + text: "The save() method *must* push a copy of the current drawing state onto the drawing state stack<^>." + - id: 2d.state.restore + text: "The restore() method *must* pop the top entry in the drawing state stack, and reset the drawing state it describes<^>." + - id: 2d.state.restore.underflow + text: "If there is no saved state, the method *must* do nothing<^>." + + - id: 2d.transformation.initial + text: "When the context is created, the transformation matrix *must* initially be the identity transform<^>." + - id: 2d.transformation.order + text: "The transformations *must* be performed in reverse order<^>." + - id: 2d.transformation.scale + text: "The scale(x, y) method *must* add the scaling transformation described by the arguments to the transformation matrix<^>." + - id: 2d.transformation.scale.multiple + text: "The factors are multiples<^>." + - id: 2d.transformation.rotate + text: "The rotate(angle) method *must* add the rotation transformation described by the argument to the transformation matrix<^>." + - id: 2d.transformation.rotate.direction + text: "The angle argument represents a clockwise rotation angle<^>" + - id: 2d.transformation.rotate.radians + text: "The angle argument <...> expressed in radians<^>." + - id: 2d.transformation.translate + text: "The translate(x, y) method *must* add the translation transformation described by the arguments to the transformation matrix<^>." + - id: 2d.transformation.transform + text: "The transform(a, b, c, d, e, f) method *must* replace the current transformation matrix with the result of multiplying the current transformation matrix with the matrix described by<^>:" + - id: 2d.transformation.transform.multiply + text: "The transform(a, b, c, d, e, f) method *must* replace the current transformation matrix with the result of multiplying<^> the current transformation matrix with the matrix described by:" + - id: 2d.transformation.setTransform + text: "The setTransform(a, b, c, d, e, f) method *must* <...> invoke the transform(a, b, c, d, e, f) method with the same arguments<^>" + - id: 2d.transformation.setTransform.identity + text: "The setTransform(a, b, c, d, e, f) method *must* reset the current transform to the identity matrix<^>, " + + + - id: 2d.composite.operation + text: "All drawing operations are affected by the global compositing attributes, globalAlpha and globalCompositeOperation<^>." + + - id: 2d.composite.globalAlpha.shape + text: "The globalAlpha attribute gives an alpha value that is applied to shapes<^> and images before they are composited onto the canvas." + - id: 2d.composite.globalAlpha.image + text: "The globalAlpha attribute gives an alpha value that is applied to shapes and images<^> before they are composited onto the canvas." + - id: 2d.composite.globalAlpha.range + text: "The value must be in the range from 0.0 (fully transparent) to 1.0 (no additional transparency). If an attempt is made to set the attribute to a value outside this range, including Infinity and Not-a-Number (NaN) values, the attribute *must* retain its previous value<^>." + - id: 2d.composite.globalAlpha.default + text: "When the context is created, the globalAlpha attribute *must* initially have the value 1.0<^>." + + - id: 2d.composite.operation.shape + text: "The globalCompositeOperation attribute sets how shapes<^> and images are drawn onto the existing bitmap," + - id: 2d.composite.operation.image + text: "The globalCompositeOperation attribute sets how shapes and images<^> are drawn onto the existing bitmap," + + - id: 2d.composite.source-atop + text: "source-atop<^>" + - id: 2d.composite.source-in + text: "source-in<^>" + - id: 2d.composite.source-out + text: "source-out<^>" + - id: 2d.composite.source-over + text: "source-over (default)<^>" + - id: 2d.composite.destination-atop + text: "destination-atop<^>" + - id: 2d.composite.destination-in + text: "destination-in<^>" + - id: 2d.composite.destination-out + text: "destination-out<^>" + - id: 2d.composite.destination-over + text: "destination-over<^>" + - id: 2d.composite.lighter + text: "lighter<^>" + - id: 2d.composite.copy + text: "copy<^>" + - id: 2d.composite.xor + text: "xor<^>" + + - id: 2d.composite.operation.casesensitive + text: "These values are all case-sensitive<^> <...> they *must* be used exactly as shown." + - id: 2d.composite.operation.exact + text: "User agents *must* not recognize values that are not a case-sensitive match for one of the values given above<^>." + - id: 2d.composite.operation.porterduff + text: "The operators in the above list *must* be treated as described by the Porter-Duff operator given at the start of their description (e.g. A over B)<^>." + - id: 2d.composite.operation.unrecognised + text: "On setting, if the user agent does not recognize the specified value, it *must* be ignored, leaving the value of globalCompositeOperation unaffected<^>." + - id: 2d.composite.operation.default + text: "When the context is created, the globalCompositeOperation attribute *must* initially have the value source-over<^>." + + + - id: 2d.colours.parse + text: "On setting, strings *must* be parsed as CSS values and the color assigned<^>," + - id: 2d.gradient.assign + text: "On setting, <...> CanvasGradient<^> and CanvasPattern objects *must* be assigned themselves." + - id: 2d.pattern.assign + text: "On setting, <...> CanvasGradient and CanvasPattern<^> objects *must* be assigned themselves." + - id: 2d.colours.invalidstring + text: "If the value is a string but cannot be parsed as a CSS value<^>, <...> then it *must* be ignored, and the attribute must retain its previous value." + - id: 2d.colours.invalidtype + text: "If the value is <...> neither a string, a CanvasGradient, nor a CanvasPattern<^>, then it *must* be ignored, and the attribute must retain its previous value." + - id: 2d.colours.getcolour + text: "On getting, if the value is a color, then the serialization of the color *must* be returned<^>." + - id: 2d.gradient.object + text: "if it is not a color but a CanvasGradient<^> or CanvasPattern, then the respective object *must* be returned." + - id: 2d.pattern.object + text: "if it is not a color but a CanvasGradient or CanvasPattern<^>, then the respective object *must* be returned." + - id: 2d.serializecolour.solid + text: "if it has alpha equal to 1.0, then the string is a lowercase six-digit hex value<^>" + - id: 2d.serializecolour.transparent + text: "Otherwise, the color value has alpha less than 1.0, and the string is the color value in the CSS rgba() functional-notation format<^>:" + - id: 2d.colours.default + text: "When the context is created, the strokeStyle and fillStyle attributes *must* initially have the string value #000000<^>." + + - id: 2d.gradient.interpolate.linear + text: "Between each such stop, the colors and the alpha component *must* be linearly interpolated<^> over the RGBA space without premultiplying the alpha value to find the color to use at that offset." + - id: 2d.gradient.interpolate.alpha + text: "Between each such stop, the colors and the alpha component *must* be linearly interpolated over the RGBA space without premultiplying the alpha value<^> to find the color to use at that offset." + - id: 2d.gradient.outside.first + text: "Before the first stop, the color *must* be the color of the first stop<^>." + - id: 2d.gradient.outside.last + text: "After the last stop, the color *must* be the color of the last stop<^>." + - id: 2d.gradient.empty + text: "When there are no stops, the gradient is transparent black<^>." + + + - id: 2d.gradient.invalidoffset + text: "If the offset is less than 0, greater than 1, infinite, or NaN, then an INDEX_SIZE_ERR exception *must* be raised<^>." + - id: 2d.gradient.invalidcolour + text: "If the color cannot be parsed as a CSS value, then a SYNTAX_ERR exception *must* be raised<^>." + - id: 2d.gradient.update + text: "Otherwise, the gradient *must* have a new stop placed, at offset offset relative to the whole gradient, and with the color obtained by parsing color as a CSS value<^>." + - id: 2d.gradient.interpolate.overlap + text: "If multiple stops are added at the same offset on a gradient, they *must* be placed in the order added, with the first one closest to the start of the gradient, <...><^>." + + - id: 2d.gradient.linear.nonfinite + text: "If any of the arguments to createLinearGradient() are infinite or NaN, the method *must* raise a NOT_SUPPORTED_ERR exception<^>." + - id: 2d.gradient.linear.return + text: "Otherwise, the method *must* return a linear CanvasGradient initialized with the specified line<^>." + - id: 2d.gradient.linear.rendering + text: "Linear gradients *must* be rendered such that all points on a line perpendicular to the line that crosses the start and end points have the color at the point where those two lines cross (with the colors coming from the interpolation and extrapolation described above)<^>." + - id: 2d.gradient.linear.transform + text: "The points in the linear gradient *must* be transformed as described by the current transformation matrix when rendering<^>." + - id: 2d.gradient.linear.zerosize + text: "If x0 = x1 and y0 = y1, then the linear gradient *must* paint nothing<^>." + + - id: 2d.gradient.radial.nonfinite + text: "If any of the arguments are infinite or NaN, a NOT_SUPPORTED_ERR exception *must* be raised<^>." + - id: 2d.gradient.radial.negative + text: "If either of r0 or r1 are negative, an INDEX_SIZE_ERR exception *must* be raised<^>." + - id: 2d.gradient.radial.return + text: "Otherwise, the method *must* return a radial CanvasGradient initialized with the two specified circles<^>." + - id: 2d.gradient.radial.rendering + text: "Radial gradients *must* be rendered by following these steps<^>:" + - id: 2d.gradient.radial.equal + text: "If x0 = x1 and y0 = y1 and r0 = r1, then the radial gradient *must* paint nothing<^>." + - id: 2d.gradient.extent + text: "Gradients *must* be painted only where the relevant stroking or filling effects requires that they be drawn<^>." + - id: 2d.gradient.radial.transform + text: "The points in the radial gradient *must* be transformed as described by the current transformation matrix when rendering<^>." + + + - id: 2d.pattern.modify + text: "Modifying this image after calling the createPattern() method *must* not affect the pattern<^>." + - id: 2d.pattern.missing + text: "If the empty string is specified, repeat *must* be assumed<^>." + - id: 2d.pattern.unrecognised + text: "If an unrecognized value is given, then the user agent *must* raise a SYNTAX_ERR exception<^>." + - id: 2d.pattern.exact + text: "User agents *must* recognize the four values described above exactly (e.g. they must not do case folding)<^>." + - id: 2d.pattern.return + text: "the method *must* return a CanvasPattern object suitably initialized<^>." + - id: 2d.pattern.IDL + text: "CanvasPattern createPattern(in HTMLImageElement image, in DOMString repetition);<...>CanvasPattern createPattern(in HTMLCanvasElement image, in DOMString repetition);<...>CanvasPattern createPattern(in HTMLVideoElement image, in DOMString repetition);<^>" + - id: 2d.pattern.incomplete.image + text: "If the image argument is an HTMLImageElement object that is not fully decodable<^><...> then the implementation *must* return null." + - id: 2d.pattern.incomplete.video + previously: [ 6, "createPattern" ] + text: "If the image argument is <...> an HTMLVideoElement object whose readyState attribute is either HAVE_NOTHING or HAVE_METADATA<^>, then the implementation *must* return null." + - id: 2d.pattern.zerocanvas + previously: [ 10, "createPattern" ] + text: "If the image argument is an HTMLCanvasElement object with either a horizontal dimension or a vertical dimension equal to zero, then the implementation *must* raise an INVALID_STATE_ERR exception<^>." + - id: 2d.pattern.painting + text: "Patterns *must* be painted so that the top left of the first image is anchored at the origin of the coordinate space, and images are then repeated horizontally to the left and right (if the repeat-x string was specified) or vertically up and down (if the repeat-y string was specified) or in all four directions all over the canvas (if the repeat string was specified)<^>." + - id: 2d.pattern.unscaled + text: "The images are not scaled by this process; one CSS pixel of the image *must* be painted on one coordinate space unit<^>." + - id: 2d.pattern.extent + text: "patterns *must* actually be painted only where the stroking or filling effect requires that they be drawn<^>, and are affected by the current transformation matrix." + - id: 2d.pattern.animated.image + text: "When the createPattern() method is passed an animated image as its image argument, the user agent must use the poster frame of the animation, or, if there is no poster frame, the first frame of the animation<^>." + - id: 2d.pattern.animated.video + previously: [ 4, "createPattern" ] + text: "When the image argument is an HTMLVideoElement, then the frame at the current playback position *must* be used as the source image<^>," + - id: 2d.pattern.video.size + previously: [ 4, "createPattern" ] + text: "When the image argument is an HTMLVideoElement, <...> the source image's dimensions *must* be the intrinsic width and intrinsic height of the media resource (i.e. after any aspect-ratio correction has been applied)<^>." + + + - id: 2d.lineWidth + text: "The lineWidth attribute gives the width of lines, in coordinate space units<^>." + - id: 2d.lineWidth.get + text: "The lineWidth attribute <...>. On getting, it *must* return the current value<^>." + - id: 2d.lineWidth.invalid + text: "The lineWidth attribute <...>. On setting, zero, negative, infinite, and NaN values *must* be ignored, leaving the value unchanged<^>;" + - id: 2d.lineWidth.set + text: "The lineWidth attribute <...>. On setting, <...> other values *must* change the current value to the new value<^>." + - id: 2d.lineWidth.default + text: "the lineWidth attribute *must* initially have the value 1.0<^>." + - id: 2d.lineCap.end + text: "The lineCap attribute defines the type of endings that UAs will place on the end of lines<^>." + - id: 2d.lineCap.butt + text: "The butt value means that the end of each line has a flat edge perpendicular to the direction of the line (and that no additional line cap is added)<^>." + - id: 2d.lineCap.round + text: "The round value means that a semi-circle with the diameter equal to the width of the line *must* then be added on to the end of the line<^>." + - id: 2d.lineCap.square + text: "The square value means that a rectangle with the length of the line width and the width of half the line width, placed flat against the edge perpendicular to the direction of the line, *must* be added at the end of each line<^>." + - id: 2d.lineCap.get + previously: [ 2, "The lineCap attribute" ] + text: "On getting, it *must* return the current value<^>." + - id: 2d.lineCap.set + text: "On setting, if the new value is one of the literal strings butt, round, and square, then the current value *must* be changed to the new value<^>;" + - id: 2d.lineCap.invalid + text: "On setting, if the new value is one of the literal strings butt, round, and square, then <...>; other values *must* ignored, leaving the value unchanged<^>." + - id: 2d.lineCap.default + text: "When the context is created, the lineCap attribute *must* initially have the value butt<^>." + - id: 2d.lineJoin.get + previously: [ 2, "lineJoin" ] + text: "On getting, it *must* return the current value<^>." + - id: 2d.lineJoin.set + text: "On setting, if the new value is one of the literal strings bevel, round, and miter, then the current value *must* be changed to the new value<^>;" + - id: 2d.lineJoin.invalid + text: "On setting, if the new value is one of the literal strings bevel, round, and miter, then <...>; other values *must* be ignored, leaving the value unchanged<^>." + - id: 2d.lineJoin.default + text: "When the context is created, the lineJoin attribute *must* initially have the value miter<^>." + - id: 2d.lineJoin.joins + text: "A join exists at any point in a subpath shared by two consecutive lines<^>." + - id: 2d.lineJoin.joinclosed + text: "When a subpath is closed, then a join also exists at its first point (equivalent to its last point) connecting the first and last lines in the subpath<^>." + - id: 2d.lineJoin.common + text: "A filled triangle connecting these two opposite corners with a straight line, with the third point of the triangle being the join point, *must* be rendered at all joins<^>." + - id: 2d.lineJoin.round + text: "The round value means that a filled arc connecting the two aforementioned corners of the join, abutting (and not overlapping) the aforementioned triangle, with the diameter equal to the line width and the origin at the point of the join, *must* be rendered at joins<^>." + - id: 2d.lineJoin.bevel + text: "The bevel value means that this is all that is rendered at joins<^>." + - id: 2d.lineJoin.miter + text: "The miter value means that a second filled triangle *must* (if it can given the miter length) be rendered at the join, with one line being the line between the two aforementioned corners, abutting the first triangle, and the other two being continuations of the outside edges of the two joining lines, as long as required to intersect without going over the miter length<^>." + - id: 2d.lineJoin.miterLimit + text: "If the miter length would cause the miter limit ratio to be exceeded, this second triangle *must* not be rendered<^>." + - id: 2d.miterLimit.get + text: "The miter limit <...>. On getting, it *must* return the current value<^>." + - id: 2d.miterLimit.invalid + text: "The miter limit <...>. On setting, zero, negative, infinite, and NaN values *must* be ignored, leaving the value unchanged<^>;" + - id: 2d.miterLimit.set + text: "The miter limit <...>. On setting, <...>; other values *must* change the current value to the new value<^>." + - id: 2d.miterLimit.default + text: "When the context is created, the miterLimit attribute *must* initially have the value 10.0<^>." + + + - id: 2d.shadow.color.initial + text: "When the context is created, the shadowColor attribute initially *must* be fully-transparent black<^>." + - id: 2d.shadow.color.get + text: "On getting, the serialization of the color *must* be returned<^>." + - id: 2d.shadow.color.set + text: "On setting, the new value *must* be parsed as a CSS value and the color assigned<^>." + - id: 2d.shadow.color.invalid + text: "If the value cannot be parsed as a CSS value then it *must* be ignored, and the attribute must retain its previous value<^>." + - id: 2d.shadow.offset.initial + text: "When the context is created, the shadow offset attributes *must* initially have the value 0<^>." + - id: 2d.shadow.offset.get + text: "On getting, they *must* return their current value<^>." + - id: 2d.shadow.offset.set + text: "On setting, the attribute being set *must* be set to the new value<^>," + - id: 2d.shadow.offset.invalid + text: "On setting, <...> if the value is infinite or NaN, in which case the new value *must* be ignored<^>." + - id: 2d.shadow.blur.initial + text: "When the context is created, the shadowBlur attribute *must* initially have the value 0<^>." + - id: 2d.shadow.blur.get + text: "On getting, the attribute *must* return its current value<^>." + - id: 2d.shadow.blur.set + text: "On setting the attribute *must* be set to the new value<^>," + - id: 2d.shadow.blur.invalid + text: "On setting <...> if the value is negative, infinite or NaN, in which case the new value *must* be ignored<^>." + - id: 2d.shadow.enable + text: "Shadows are only drawn if the opacity component of the alpha component of the color of shadowColor is non-zero and either the shadowBlur is non-zero, or the shadowOffsetX is non-zero, or the shadowOffsetY is non-zero<^>." + - id: 2d.shadow.render + text: "When shadows are drawn, they *must* be rendered as follows<^>:" + + - id: 2d.rect.transform + text: "The current transformation matrix *must* be applied to the following four coordinates<^>," + - id: 2d.rect.closed + text: "the following four coordinates, which form the path that *must* then be closed to get the specified rectangle<^>:" + - id: 2d.clearRect + text: "The clearRect(x, y, w, h) method *must* clear the pixels in the specified rectangle that also intersect the current clipping region to a fully transparent black, erasing any previous image<^>." + - id: 2d.fillRect + text: "The fillRect(x, y, w, h) method *must* paint the specified rectangular area using the fillStyle<^>." + - id: 2d.strokeRect + text: "The strokeRect(x, y, w, h) method *must* stroke the specified rectangle's path using the strokeStyle, lineWidth, lineJoin, and (if appropriate) miterLimit attributes<^>." + + + - id: 2d.path.initial + text: "Initially, the context's path *must* have zero subpaths<^>." + - id: 2d.path.transformation + text: "The points and lines added to the path by these methods *must* be transformed according to the current transformation matrix as they are added<^>." + - id: 2d.path.beginPath + text: "The beginPath() method *must* empty the list of subpaths so that the context once again has zero subpaths<^>." + - id: 2d.path.moveTo + text: "The moveTo(x, y) method *must* create a new subpath with the specified point as its first (and only) point<^>." + - id: 2d.path.ensure + text: "When the user agent is to ensure there is a subpath for a coordinate (x, y), the user agent must check to see if the context has any subpaths, and if it does not, then the user agent *must* create a new subpath with the point (x, y) as its first (and only) point, as if the moveTo() method had been called<^>." + - id: 2d.path.closePath.empty + text: "The closePath() method *must* do nothing if the context has no subpaths<^>." + - id: 2d.path.closePath.nonempty + text: "The closePath() method <...> *must* mark the last subpath as closed, create a new subpath whose first point is the same as the previous subpath's first point, and finally add this new subpath to the path<^>." + - id: 2d.path.lineTo.empty + text: "The lineTo(x, y) method *must* ensure there is a subpath for (x, y) if the context has no subpaths<^>." + - id: 2d.path.lineTo.nonempty + text: "The lineTo(x, y) method <...> *must* connect the last point in the subpath to the given point (x, y) using a straight line, and must then add the given point (x, y) to the subpath<^>." + - id: 2d.path.quadratic.empty + text: "The quadraticCurveTo(cpx, cpy, x, y) method *must* ensure there is a subpath for (cpx, cpy)<^>," + - id: 2d.path.quadratic.nonempty + text: "The quadraticCurveTo(cpx, cpy, x, y) method <...> *must* connect the last point in the subpath to the given point (x, y) using a quadratic B<...>zier curve with control point (cpx, cpy), and must then add the given point (x, y) to the subpath<^>." + - id: 2d.path.bezier.empty + text: "The bezierCurveTo(cp1x, cp1y, cp2x, cp2y, x, y) method *must* ensure there is a subpath for (cp1x, cp1y)<^>," + - id: 2d.path.bezier.nonempty + text: "The bezierCurveTo(cp1x, cp1y, cp2x, cp2y, x, y) method <...> *must* connect the last point in the subpath to the given point (x, y) using a cubic B<...>zier curve with control points (cp1x, cp1y) and (cp2x, cp2y). Then, it must add the point (x, y) to the subpath<^>." + - id: 2d.path.arcTo.empty + text: "The arcTo(x1, y1, x2, y2, radius) method *must* first ensure there is a subpath for (x1, y1)<^>." + - id: 2d.path.arcTo.negative + previously: [ 2, "arcTo(" ] + text: "Negative values for radius *must* cause the implementation to raise an INDEX_SIZE_ERR exception<^>." + - id: 2d.path.arcTo.coincide.01 + text: "If the point (x0, y0) is equal to the point (x1, y1)<^>, or if the point (x1, y1) is equal to the point (x2, y2), or if the radius radius is zero, then the method *must* add the point (x1, y1) to the subpath, and connect that point to the previous point (x0, y0) by a straight line." + - id: 2d.path.arcTo.coincide.12 + text: "If the point (x0, y0) is equal to the point (x1, y1), or if the point (x1, y1) is equal to the point (x2, y2)<^>, or if the radius radius is zero, then the method *must* add the point (x1, y1) to the subpath, and connect that point to the previous point (x0, y0) by a straight line." + - id: 2d.path.arcTo.zeroradius + text: "If the point (x0, y0) is equal to the point (x1, y1), or if the point (x1, y1) is equal to the point (x2, y2), or if the radius radius is zero<^>, then the method *must* add the point (x1, y1) to the subpath, and connect that point to the previous point (x0, y0) by a straight line." + - id: 2d.path.arcTo.collinear + text: "if the points (x0, y0), (x1, y1), and (x2, y2) all lie on a single straight line, then the method *must* add the point (x1, y1) to the subpath, and connect that point to the previous point (x0, y0) by a straight line<^>." + - id: 2d.path.arcTo.shape + text: "The method *must* connect the point (x0, y0) to the start tangent point by a straight line, adding the start tangent point to the subpath, and then must connect the start tangent point to the end tangent point by The Arc, adding the end tangent point to the subpath<^>." + + - id: 2d.path.arc.nonempty + text: "If the context has any subpaths, then the method *must* add a straight line from the last point in the subpath to the start point of the arc<^>." + - id: 2d.path.arc.draw + text: "it *must* draw the arc between the start point of the arc and the end point of the arc, and add the start and end points of the arc to the subpath<^>." + - id: 2d.path.arc.zero + text: "If the two points are the same, or if the radius is zero<^>, then the arc is defined as being of zero length in both directions." + - id: 2d.path.arc.negative + previously: [ 2, "anticlockwise" ] + text: "Negative values for radius *must* cause the implementation to raise an INDEX_SIZE_ERR exception<^>." + + - id: 2d.path.rect.subpath + text: "The rect(x, y, w, h) method *must* create a new subpath containing just the four points (x, y), (x+w, y), (x+w, y+h), (x, y+h), with those four points connected by straight lines<^>" + - id: 2d.path.rect.closed + text: "The rect(x, y, w, h) method <...> *must* then mark the subpath as closed<^>." + - id: 2d.path.rect.newsubpath + text: "The rect(x, y, w, h) method <...> *must* then create a new subpath with the point (x, y) as the only point in the subpath<^>." + + - id: 2d.path.fill.basic + text: "The fill() method *must* fill all the subpaths of the current path, using fillStyle, and using the non-zero winding number rule<^>." + - id: 2d.path.fill.closed + text: "Open subpaths *must* be implicitly closed when being filled (without affecting the actual subpaths)<^>." + - id: 2d.path.stroke.basic + text: "The stroke() method *must* calculate the strokes of all the subpaths of the current path, using the lineWidth, lineCap, lineJoin, and (if appropriate) miterLimit attributes, and then fill the combined stroke area using the strokeStyle attribute<^>." + - id: 2d.path.unaffected + text: "Paths, when filled or stroked, *must* be painted without affecting the current path<^>" + - id: 2d.path.subjected + text: "Paths, when filled or stroked, <...> *must* be subject to shadow effects, global alpha, the clipping region, and global composition operators<^>." + + - id: 2d.path.stroke.prune + text: "Zero-length line segments *must* be pruned before stroking a path<^>." + - id: 2d.path.stroke.empty + text: "Empty subpaths *must* be ignored<^>." + + - id: 2d.path.clip.basic + text: "The clip() method *must* create a new clipping region by calculating the intersection of the current clipping region and the area described by the current path, using the non-zero winding number rule<^>." + - id: 2d.path.clip.closed + text: "Open subpaths *must* be implicitly closed when computing the clipping region, without affecting the actual subpaths<^>." + - id: 2d.path.clip.initial + text: "When the context is initialized, the clipping region *must* be set to the rectangle with the top left corner at (0,0) and the width and height of the coordinate space<^>." + - id: 2d.path.isPointInPath + text: "The isPointInPath(x, y) method *must* return true if the point given by the x and y coordinates passed to the method, when treated as coordinates in the canvas coordinate space unaffected by the current transformation, is inside the current path as determined by the non-zero winding number rule; and must return false otherwise<^>." + - id: 2d.path.isPointInPath.edge + text: "The isPointInPath(x, y) method *must* return true if <...>. Points on the path itself are considered to be inside the path<^>." + - id: 2d.path.isPointInPath.nonfinite + text: "If either of the arguments is infinite or NaN, then the method *must* return false<^>." + + # TODO: Focus management + + - id: 2d.text.font.parse + text: "The font IDL attribute, on setting, *must* be parsed the same way as the 'font' property of CSS (but without supporting property-independent style sheet syntax like 'inherit')<^>," + - id: 2d.text.font.lineheight + text: "The font IDL attribute, on setting, *must* be parsed <...> with the 'line-height' component forced to 'normal'<^>," + - id: 2d.text.font.fontsize + text: "The font IDL attribute, on setting, *must* be parsed <...> with the 'font-size' component converted to CSS pixels<^>," + - id: 2d.text.font.systemfonts + text: "The font IDL attribute, on setting, *must* be parsed <...> with system fonts being computed to explicit values<^>." + - id: 2d.text.font.invalid + text: "If the new value is syntactically incorrect (including using property-independent style sheet syntax like 'inherit' or 'initial'), then it *must* be ignored, without assigning a new font value<^>." + + - id: 2d.text.font.fontface + text: "Font names must be interpreted in the context of the canvas element's stylesheets; any fonts embedded using @font-face *must* therefore be available once they are loaded<^>." + - id: 2d.text.font.notfullyloaded + text: "If a font is referenced before it is fully loaded, then it *must* be treated as if it was an unknown font, falling back to another as described by the relevant CSS specifications<^>." + - id: 2d.text.font.get + text: "On getting, the font attribute *must* return the serialized form of the current font of the context (with no 'line-height' component)<^>." + - id: 2d.text.font.default + text: "When the context is created, the font of the context *must* be set to 10px sans-serif<^>." + - id: 2d.text.font.size + text: "When the 'font-size' component is set to lengths using percentages, 'em' or 'ex' units, or the 'larger' or 'smaller' keywords, these *must* be interpreted relative to the computed value of the 'font-size' property of the corresponding canvas element at the time that the attribute is set<^>." + - id: 2d.text.font.weight + text: "When the 'font-weight' component is set to the relative values 'bolder' and 'lighter', these *must* be interpreted relative to the computed value of the 'font-weight' property of the corresponding canvas element at the time that the attribute is set<^>." + - id: 2d.text.font.undefined + text: "If the computed values are undefined for a particular case (e.g. because the canvas element is not in a Document), then the relative keywords *must* be interpreted relative to the normal-weight 10px sans-serif default<^>." + - id: 2d.text.align.get + text: "The textAlign IDL attribute, on getting, *must* return the current value<^>." + - id: 2d.text.align.set + text: "On setting, if the value is one of start, end, left, right, or center, then the value *must* be changed to the new value<^>." + - id: 2d.text.align.invalid + text: "The textAlign IDL attribute, <...> Otherwise, the new value *must* be ignored<^>." + - id: 2d.text.align.default + text: "When the context is created, the textAlign attribute *must* initially have the value start<^>." + - id: 2d.text.baseline.get + text: "The textBaseline IDL attribute, on getting, *must* return the current value<^>." + - id: 2d.text.baseline.set + text: "On setting, if the value is one of top, hanging, middle, alphabetic, ideographic, or bottom, then the value *must* be changed to the new value<^>." + - id: 2d.text.baseline.invalid + text: "The textBaseline IDL attribute, <...> Otherwise, the new value *must* be ignored<^>." + - id: 2d.text.baseline.default + text: "When the context is created, the textBaseline attribute *must* initially have the value alphabetic<^>." + + - id: 2d.text.draw + text: "The fillText() and strokeText() methods <...> when the methods are called, the user agent *must* run the following steps<^>:" + - id: 2d.text.draw.spaces + text: "Replace all the space characters in text with U+0020 SPACE characters<^>." + - id: 2d.text.draw.direction + text: "the 'direction' property of the inline box set to the directionality of the canvas element<^>," + - id: 2d.text.draw.maxwidth + text: "If the maxWidth argument was specified and the hypothetical width of the inline box in the hypothetical line box is greater than maxWidth CSS pixels, then change font to have a more condensed font (if one is available or if a reasonably readable one can be synthesized by applying a horizontal scale factor to the font) or a smaller font, and return to the previous step<^>." + - id: 2d.text.align.left + text: "Let the anchor point's horizontal position be the left edge of the inline box<^>." + - id: 2d.text.align.right + text: "Let the anchor point's horizontal position be the right edge of the inline box<^>." + - id: 2d.text.align.center + text: "Let the anchor point's horizontal position be half way between the left and right edges of the inline box<^>." + + - id: 2d.text.baseline.top + text: "Let the anchor point's vertical position be the top of the em box of the first available font of the inline box<^>." + - id: 2d.text.baseline.hanging + text: "Let the anchor point's vertical position be the hanging baseline of the first available font of the inline box<^>." + - id: 2d.text.baseline.middle + text: "Let the anchor point's vertical position be half way between the bottom and the top of the em box of the first available font of the inline box<^>." + - id: 2d.text.baseline.alphabetic + text: "Let the anchor point's vertical position be the alphabetic baseline of the first available font of the inline box<^>." + - id: 2d.text.baseline.ideographic + text: "Let the anchor point's vertical position be the ideographic baseline of the first available font of the inline box<^>." + - id: 2d.text.baseline.bottom + text: "Let the anchor point's vertical position be the bottom of the em box of the first available font of the inline box<^>." + + - id: 2d.text.draw.fill + text: "For fillText() fillStyle must be applied to the glyphs and strokeStyle *must* be ignored<^>." + - id: 2d.text.draw.stroke + text: "For strokeText() the reverse holds and strokeStyle must be applied to the glyph outlines and fillStyle *must* be ignored<^>." + - id: 2d.text.measure.spaces + text: "When the method is invoked, the user agent *must* replace all the space characters in text with U+0020 SPACE characters<^>," + - id: 2d.text.measure + text: "When the method is invoked, the user agent <...> *must* form a hypothetical infinitely wide CSS line box containing a single inline box containing the text text, with all the properties at their initial values except the 'white-space' property of the inline element set to 'pre' and the 'font' property of the inline element set to the current font of the context as given by the font attribute, and must then return a new TextMetrics object with its width attribute set to the width of that inline box, in CSS pixels<^>." + + - id: 2d.drawImage.defaultdest + text: "If not specified, the dw and dh arguments *must* default to the values of sw and sh, interpreted such that one CSS pixel in the image is treated as one unit in the canvas coordinate space<^>." + - id: 2d.drawImage.defaultsource + text: "If the sx, sy, sw, and sh arguments are omitted, they *must* default to 0, 0, the image's intrinsic width in image pixels, and the image's intrinsic height in image pixels, respectively<^>." + - id: 2d.drawImage.IDL + text: "void drawImage(in HTMLVideoElement image, in double sx, in double sy, in double sw, in double sh, in double dx, in double dy, in double dw, in double dh);<^>" + - id: 2d.drawImage.incomplete.image + text: "If the image argument is an HTMLImageElement object that is not fully decodable<^><...> then the implementation *must* return without drawing anything." + - id: 2d.drawImage.incomplete.video + previously: [ 6, "dw and dh" ] + text: "If the image argument is <...> an HTMLVideoElement object whose readyState attribute is either HAVE_NOTHING or HAVE_METADATA<^>, then the implementation *must* return without drawing anything." + - id: 2d.drawImage.zerocanvas + previously: [ 10, "dw and dh" ] + text: "If the image argument is an HTMLCanvasElement object with either a horizontal dimension or a vertical dimension equal to zero, then the implementation *must* raise an INVALID_STATE_ERR exception<^>." + - id: 2d.drawImage.zerosource + text: "If one of the sw or sh arguments is zero<^>, the implementation *must* raise an INDEX_SIZE_ERR exception." + - id: 2d.drawImage.paint + text: "When drawImage() is invoked, the region of the image specified by the source rectangle *must* be painted on the region of the canvas specified by the destination rectangle<^>, after applying the current transformation matrix to the points of the destination rectangle." + - id: 2d.drawImage.original + text: "The original image data of the source image *must* be used, not the image as it is rendered (e.g. width and height attributes on the source element have no effect)<^>." + - id: 2d.drawImage.direction + text: "The image data *must* be processed in the original direction, even if the dimensions given are negative<^>." + - id: 2d.drawImage.self + text: "When a canvas is drawn onto itself, the drawing model requires the source to be copied before the image is drawn back onto the canvas, so it is possible to copy parts of a canvas onto overlapping parts of itself<^>." + - id: 2d.drawImage.animated.image + text: "When the drawImage() method is passed an animated image as its image argument, the user agent *must* use the poster frame of the animation, or, if there is no poster frame, the first frame of the animation<^>." + - id: 2d.drawImage.animated.video + previously: [ 4, "drawImage" ] + text: "When the image argument is an HTMLVideoElement, then the frame at the current playback position *must* be used as the source image<^>," + - id: 2d.drawImage.video.size + previously: [ 4, "drawImage" ] + text: "When the image argument is an HTMLVideoElement, <...> the source image's dimensions *must* be the intrinsic width and intrinsic height of the media resource (i.e. after any aspect-ratio correction has been applied)<^>." + - id: 2d.drawImage.unaffect + text: "Images are painted without affecting the current path<^>" + - id: 2d.drawImage.subject + text: "Images are painted without affecting the current path, and are subject to shadow effects, global alpha, the clipping region, and global composition operators<^>." + + + - id: 2d.imageData.create2.object + text: "When the method is invoked with two arguments sw and sh, it *must* return an ImageData object<^>" + - id: 2d.imageData.create2.size + text: "When the method is invoked with two arguments sw and sh, it *must* return an ImageData object representing a rectangle with a width in CSS pixels equal to the absolute magnitude of sw and a height in CSS pixels equal to the absolute magnitude of sh<^>." + - id: 2d.imageData.create1.object + text: "When invoked with a single imagedata argument, it *must* return an ImageData object<^>" + - id: 2d.imageData.create1.size + text: "When invoked with a single imagedata argument, it *must* return an ImageData object representing a rectangle with the same dimensions as the ImageData object passed as the argument<^>." + - id: 2d.imageData.create.initial + text: "The ImageData object returned must be filled with transparent black<^>." + + - id: 2d.imageData.get.object + text: "The getImageData(sx, sy, sw, sh) method *must* return an ImageData object<^>" + - id: 2d.imageData.get.basic + text: "The getImageData(sx, sy, sw, sh) method *must* return an ImageData object representing the underlying pixel data for the area of the canvas denoted by the rectangle whose corners are the four points (sx, sy), (sx+sw, sy), (sx+sw, sy+sh), (sx, sy+sh), in canvas coordinate space units<^>." + - id: 2d.imageData.get.outside + text: "Pixels outside the canvas *must* be returned as transparent black<^>." + - id: 2d.imageData.get.premul + text: "Pixels *must* be returned as non-premultiplied alpha values<^>." + + - id: 2d.imageData.getcreate.nonfinite + text: "If any of the arguments to createImageData() or getImageData() are infinite or NaN<^>, the method *must* instead raise a NOT_SUPPORTED_ERR exception." + - id: 2d.imageData.create.null + text: "ImageData createImageData(in ImageData imagedata);<^>" + - id: 2d.imageData.getcreate.zero + text: "If either the sw or sh arguments are zero, the method *must* instead raise an INDEX_SIZE_ERR exception<^>." + + - id: 2d.imageData.initial + text: "ImageData objects *must* be initialized so that their width attribute is set to w, the number of physical device pixels per row in the image data, their height attribute is set to h, the number of rows in the image data, and their data attribute is initialized to a CanvasPixelArray object holding the image data<^>." + - id: 2d.imageData.one + text: "At least one pixel's worth of image data *must* be returned<^>." + - id: 2d.pixelarray.order + text: "The data *must* be represented in left-to-right order, row by row top to bottom, starting with the top left, with each pixel's red, green, blue, and alpha components being given in that order for each pixel<^>." + - id: 2d.pixelarray.range + text: "Each component of each device pixel represented in this array *must* be in the range 0..255, representing the 8 bit value for that component<^>." + - id: 2d.pixelarray.indexes + text: "The components *must* be assigned consecutive indices starting with 0 for the top left pixel's red component<^>." + - id: 2d.pixelarray.length + text: "The length attribute of a CanvasPixelArray object *must* return this number<^>." + - id: 2d.pixelarray.retrieve + text: "To determine the value of an indexed property index, the user agent *must* return the value of the indexth component in the array<^>." + - id: 2d.pixelarray.modify + text: "To set the value of an existing indexed property index to value value, the value of the indexth component in the array *must* be set to value<^>." + + - id: 2d.imageData.put.nonfinite + text: "If any of the arguments to the method are infinite or NaN, the method *must* raise a NOT_SUPPORTED_ERR exception<^>." + - id: 2d.imageData.put.wrongtype + text: "void putImageData(in ImageData imagedata, in double dx, in double dy);<...>void putImageData(in ImageData imagedata, in double dx, in double dy, in double dirtyX, in double dirtyY, in double dirtyWidth, in double dirtyHeight);<^>" + - id: 2d.imageData.put.3arg + text: "When the last four arguments are omitted, they *must* be assumed to have the values 0, 0, the width member of the imagedata structure, and the height member of the imagedata structure, respectively<^>." + - id: 2d.imageData.put.normal + text: "When invoked with arguments that do not, per the last few paragraphs, cause an exception to be raised, the putImageData() method *must* act as follows<^>:" + + - id: 2d.imageData.unchanged + text: "the following *must* result in no visible changes to the rendering<^>:" + - id: 2d.imageData.createround + text: "...*must* return ImageData objects with the same dimensions, for any value of w and h<^>." + - id: 2d.imageData.unaffected + text: "The current path, transformation matrix, shadow attributes, global alpha, the clipping region, and global composition operator *must* not affect the getImageData() and putImageData() methods<^>." + + - id: 2d.drawingmodel + text: "When a shape or image is painted, user agents *must* follow these steps, in the order given (or act as if they do)<^>:" + + - id: 2d.colorspace.correction + text: "The canvas APIs *must* perform color correction at only two points: when rendering images with their own gamma correction and color space information onto the canvas, to convert the image to the color space used by the canvas (e.g. using the 2D Context's drawImage() method with an HTMLImageElement object)<^>," + - id: 2d.colorspace.toDataURL.info + text: "The toDataURL() method *must* not include color space information in the resource returned<^>." + - id: 2d.colorspace.toDataURL.equal + text: "Where the output format allows it, the color of pixels in resources created by toDataURL() *must* match those returned by the getImageData() method<^>." + - id: 2d.colorspace.match + text: "In user agents that support CSS, the color space used by a canvas element *must* match the color space used for processing any colors for that element in CSS<^>." + - id: 2d.colorspace.img.equal + text: "The gamma correction and color space information of images *must* be handled in such a way that an image rendered directly using an img element would use the same colors as one painted on a canvas element that is then itself rendered<^>." + - id: 2d.colorspace.img.noinfo + text: "Furthermore, the rendering of images that have no color correction information (such as those returned by the toDataURL() method) *must* be rendered with no color correction<^>." + + - id: security.start + text: "All canvas elements *must* start with their origin-clean set to true<^>." + - id: security.drawImage.image + keyword: must + text: "The element's 2D context's drawImage() method is called with an HTMLImageElement or an HTMLVideoElement whose origin is not the same as that of the Document object that owns the canvas element<^>." + - id: security.drawImage.canvas + keyword: must + text: "The element's 2D context's drawImage() method is called with an HTMLCanvasElement whose origin-clean flag is false<^>." + - id: security.fillStyle.image + keyword: must + text: "The element's 2D context's fillStyle attribute is set to a CanvasPattern object that was created from an HTMLImageElement<^> or an HTMLVideoElement whose origin was not the same as that of the Document object that owns the canvas element when the pattern was created." + - id: security.fillStyle.video + keyword: must + text: "The element's 2D context's fillStyle attribute is set to a CanvasPattern object that was created from an HTMLImageElement or an HTMLVideoElement<^> whose origin was not the same as that of the Document object that owns the canvas element when the pattern was created." + - id: security.fillStyle.canvas + keyword: must + text: "The element's 2D context's fillStyle attribute is set to a CanvasPattern object that was created from an HTMLCanvasElement whose origin-clean flag was false when the pattern was created<^>." + - id: security.strokeStyle.image + keyword: must + text: "The element's 2D context's strokeStyle attribute is set to a CanvasPattern object that was created from an HTMLImageElement<^> or an HTMLVideoElement whose origin was not the same as that of the Document object that owns the canvas element when the pattern was created." + - id: security.strokeStyle.video + keyword: must + text: "The element's 2D context's strokeStyle attribute is set to a CanvasPattern object that was created from an HTMLImageElement or an HTMLVideoElement<^> whose origin was not the same as that of the Document object that owns the canvas element when the pattern was created." + - id: security.strokeStyle.canvas + keyword: must + text: "The element's 2D context's strokeStyle attribute is set to a CanvasPattern object that was created from an HTMLCanvasElement whose origin-clean flag was false when the pattern was created<^>." + - id: security.toDataURL + text: "Whenever the toDataURL() method of a canvas element whose origin-clean flag is set to false is called, the method *must* raise a SECURITY_ERR exception<^>." + - id: security.getImageData + text: "Whenever the getImageData() method of the 2D context of a canvas element whose origin-clean flag is set to false is called with otherwise correct arguments, the method *must* raise a SECURITY_ERR exception<^>." diff --git a/testing/web-platform/tests/2dcontext/tools/specextract.py b/testing/web-platform/tests/2dcontext/tools/specextract.py new file mode 100644 index 000000000..042c0bd84 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/tools/specextract.py @@ -0,0 +1,57 @@ +import html5lib +import html5lib.treebuilders.dom + +# Expected use: +# curl --compressed http://www.whatwg.org/specs/web-apps/current-work/ >current-work +# python specextract.py +# +# Generates current-work-canvas.xhtml, for use by gentest.py to create the annotated spec document + +def extract(): + parser = html5lib.html5parser.HTMLParser(tree=html5lib.treebuilders.dom.TreeBuilder) + doc = parser.parse(open('current-work', "r"), encoding='utf-8') + + head = doc.getElementsByTagName('head')[0] + for n in head.childNodes: + if n.tagName == 'script': + head.removeChild(n) + + header = doc.getElementsByTagName('header')[0] + #thecanvas = doc.getElementById('the-canvas') # doesn't work (?!) + thecanvas = [ n for n in doc.getElementsByTagName('h4') if n.getAttribute('id') == 'the-canvas-element' ][0] + + keep = [header, thecanvas] + node = thecanvas.nextSibling + while node.nodeName != 'h4': + keep.append(node) + node = node.nextSibling + p = thecanvas.parentNode + for n in p.childNodes[:]: + if n not in keep: + p.removeChild(n) + + for n in header.childNodes[3:-4]: + header.removeChild(n) + + def make_absolute(uri): + if uri.startswith('data:'): + return uri + elif uri[0] == '/': + return 'http://www.whatwg.org' + uri + else: + return 'http://www.whatwg.org/specs/web-apps/current-work/' + uri + + # Fix the stylesheet, icon and image references + for e in doc.getElementsByTagName('link'): + e.setAttribute('href', make_absolute(e.getAttribute('href'))) + for img in doc.getElementsByTagName('img'): + img.setAttribute('src', make_absolute(img.getAttribute('src'))) + + # Convert to XHTML, because it's quicker to re-parse than HTML5 + doc.documentElement.setAttribute('xmlns', 'http://www.w3.org/1999/xhtml') + doc.documentElement.setAttribute('xml:lang', doc.documentElement.getAttribute('lang')) + doc.removeChild(doc.firstChild) # remove the DOCTYPE + + open('current-work-canvas.xhtml', 'w').write(doc.toxml(encoding = 'UTF-8')) + +extract() diff --git a/testing/web-platform/tests/2dcontext/tools/templates.yaml b/testing/web-platform/tests/2dcontext/tools/templates.yaml new file mode 100644 index 000000000..a67f3aad4 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/tools/templates.yaml @@ -0,0 +1,378 @@ +# Copyright (c) 2010 Philip Taylor +# Released under the BSD license and W3C Test Suite License: see LICENSE.txt + +framed: | + + Canvas test: %(name)s + + + %(fonts)s +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + %(name_wrapped)s +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              [show output] + %(fonthack)s

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + %(fallback)s + %(expected)s +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + %(images)s + +standalone: | + + Canvas test: %(name)s + + + + + %(fonts)s +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + < + [index] + > +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                %(backrefs)s

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                %(desc)s

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                References: +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + %(refs)s +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + %(notes)s + %(fonthack)s

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + %(fallback)s + %(expected)s +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + %(images)s + +minimal: | + + + Canvas test: %(name)s + + + + + %(fonts)s +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Pass

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Fail

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + %(fonthack)s

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  These images should be identical:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + %(fallback)s + %(expected)s +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + %(images)s + +w3c: | + + + Canvas test: %(name)s + + + + + %(fonts)s + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    %(name)s

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    %(desc)s

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + %(notes)s + %(fonthack)s

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + %(fallback)s + %(expected)s +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + %(scripts)s%(images)s + +mochitest: | + + %(mochi_name_fn)s + %(mochi_desc)s + + + %(fonts)s + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Canvas test: %(mochi_name)s

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + %(mochi_desc)s%(fonthack)s%(fallback)s + + %(mochi_images)s + +mochitest.isPixel: | + function isPixel(ctx, x,y, r,g,b,a, pos, colour, d) { + var pixel = ctx.getImageData(x, y, 1, 1); + var pr = pixel.data[0], + pg = pixel.data[1], + pb = pixel.data[2], + pa = pixel.data[3]; + ok(r-d <= pr && pr <= r+d && + g-d <= pg && pg <= g+d && + b-d <= pb && pb <= b+d && + a-d <= pa && pa <= a+d, + "pixel "+pos+" is "+pr+","+pg+","+pb+","+pa+"; expected "+colour+" +/- "+d); + } + +mochitest.todo_isPixel: | + function todo_isPixel(ctx, x,y, r,g,b,a, pos, colour, d) { + var pixel = ctx.getImageData(x, y, 1, 1); + var pr = pixel.data[0], + pg = pixel.data[1], + pb = pixel.data[2], + pa = pixel.data[3]; + todo(r-d <= pr && pr <= r+d && + g-d <= pg && pg <= g+d && + b-d <= pb && pb <= b+d && + a-d <= pa && pa <= a+d, + "pixel "+pos+" is "+pr+","+pg+","+pb+","+pa+"; expected "+colour+" +/- "+d); + } + +mochitest.deferTest: | + function deferTest() { + _deferred = true; + } + +mochitest.wrapFunction: | + function wrapFunction(f) { + return function () { + f.apply(null, arguments); + SimpleTest.finish(); + } + } + +mochitest.exception: | + var _thrown_outer = false; + try { + + %s + } catch (e) { + _thrown_outer = true; + } + todo(!_thrown_outer, 'should not throw exception'); + +mochitest.Makefile: | + # + # ***** BEGIN LICENSE BLOCK ***** + # Version: MPL 1.1/GPL 2.0/LGPL 2.1 + # + # The contents of this file are subject to the Mozilla Public License Version + # 1.1 (the "License"); you may not use this file except in compliance with + # the License. You may obtain a copy of the License at + # http://www.mozilla.org/MPL/ + # + # Software distributed under the License is distributed on an "AS IS" basis, + # WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License + # for the specific language governing rights and limitations under the + # License. + # + # The Original Code is mozilla.org code. + # + # The Initial Developer of the Original Code is + # Mozilla Corporation. + # Portions created by the Initial Developer are Copyright (C) 2007 + # the Initial Developer. All Rights Reserved. + # + # Contributor(s): + # Philip Taylor + # + # Alternatively, the contents of this file may be used under the terms of + # either of the GNU General Public License Version 2 or later (the "GPL"), + # or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"), + # in which case the provisions of the GPL or the LGPL are applicable instead + # of those above. If you wish to allow use of your version of this file only + # under the terms of either the GPL or the LGPL, and not to allow others to + # use your version of this file under the terms of the MPL, indicate your + # decision by deleting the provisions above and replace them with the notice + # and other provisions required by the GPL or the LGPL. If you do not delete + # the provisions above, a recipient may use your version of this file under + # the terms of any one of the MPL, the GPL or the LGPL. + # + # ***** END LICENSE BLOCK ***** + + DEPTH = ../../.. + topsrcdir = @top_srcdir@ + srcdir = @srcdir@ + VPATH = @srcdir@ + relativesrcdir = content/canvas/test + + include $(DEPTH)/config/autoconf.mk + include $(topsrcdir)/config/rules.mk + + +index.frame: | + + Canvas tests - %(category)s.* + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      [index] +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      %(backrefs)s.*

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +# FF trunk doesn't do onload in object, so use iframe instead +#index.frame.item: |- +# (object fallback) +index.frame.item: |- + + +index.w3c.frame: | + + Canvas tests - %(category)s.* + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      [index] +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      %(backrefs)s.*

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +index.w3c.frame.item: |- + + +index: | + + Canvas tests - index + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      <canvas> tests

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Developed by Philip Taylor. + Last updated %(updated)s. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Based on the HTML + Draft Standard — 22 February 2010. See also the annotated specification. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      See test results for some browsers. + (Generated semi-automatically via the report generator.) + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      You may want to download the source + code/data (e.g. to create an offline copy of the tests). + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Test cases

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      For each test, a green background indicates success, red indicates + failure, blue indicates a need to manually confirm the output is as + expected. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      The versions in the report generator are the most visually minimalist. + The category links below show the actual and expected renderings, and any + error messages. The individual test pages have links to relevant parts of + the specification and extra notes. + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      There may be many inaccuracies: tests that do not notice when part of + the output is incorrect; tests that are too intolerant of acceptable + renderings differences, or make other unreasonable assumptions; tests that + were written for an outdated version of the specification, and tests that + are just wrong. Also a number of features are not tested, most notably text + rendering. Please contact me (email, IRC, etc) if you find any + problems. + +index.w3c: | + + Canvas tests - index + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      <canvas> tests

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +index.category.item: | +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    • %s.*

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      %d test%s expand

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +index.w3c.category.item: | +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    • %s.*

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      %d test%s

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +reportgen: | + + Canvas tests - report generator + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      This is mainly for my own use, so it is not designed to be user-friendly. + If anyone else wants to use it for some reason, just wait + until "tests not yet loaded" and "tests not yet completed" get down to zero, then click the + pass/fail button for any test it shows where it cannot work out the answer (or use the + y/n keys to choose for the magenta-highlighted case), then use the + buttons at the bottom to collect all the results. +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + + +


                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +


                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Test name + Test case + Pass? + Fail? + Notes + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + (Submissions will tend to be ignored unless there + is a good reason why they won't be, so don't use this form unless there is such a reason.) +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +results: | + + Canvas tests - results + + + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Test diff --git a/testing/web-platform/tests/2dcontext/tools/tests.yaml b/testing/web-platform/tests/2dcontext/tools/tests.yaml new file mode 100644 index 000000000..083dfd1bd --- /dev/null +++ b/testing/web-platform/tests/2dcontext/tools/tests.yaml @@ -0,0 +1,1068 @@ +# Copyright (c) 2010 Philip Taylor +# Released under the BSD license and W3C Test Suite License: see LICENSE.txt + +- name: fallback.basic + desc: Fallback content is inserted into the DOM + testing: + - fallback + code: | + @assert canvas.childNodes.length === 1; + +- name: fallback.multiple + desc: Fallback content with multiple elements + testing: + - fallback + fallback: '

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      ' + code: | + @assert canvas.childNodes.length === 2; + +- name: fallback.nested + desc: Fallback content containing another canvas (mostly testing parsers) + testing: + - fallback + fallback: '

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      ' + code: | + @assert canvas.childNodes.length === 2; + +- name: type.name + desc: HTMLCanvasElement type and toString + testing: + - canvas.type + code: | + @assert Object.prototype.toString.call(canvas) === '[object HTMLCanvasElement]'; + +- name: type.exists + desc: HTMLCanvasElement is a property of window + notes: &bindings Defined in "Web IDL" (draft) + testing: + - canvas.type + code: | + @assert window.HTMLCanvasElement; + +- name: type.delete + desc: window.HTMLCanvasElement interface object is [[Configurable]] + notes: *bindings + testing: + - canvas.type + code: | + @assert delete window.HTMLCanvasElement === true; + @assert window.HTMLCanvasElement === undefined; + +- name: type.prototype + desc: window.HTMLCanvasElement has prototype, which is { ReadOnly, DontDelete }. prototype has getContext, which is not + notes: *bindings + testing: + - canvas.type + code: | + @assert window.HTMLCanvasElement.prototype; + @assert window.HTMLCanvasElement.prototype.getContext; + window.HTMLCanvasElement.prototype = null; + @assert window.HTMLCanvasElement.prototype; + delete window.HTMLCanvasElement.prototype; + @assert window.HTMLCanvasElement.prototype; + window.HTMLCanvasElement.prototype.getContext = 1; + @assert window.HTMLCanvasElement.prototype.getContext === 1; + delete window.HTMLCanvasElement.prototype.getContext; + @assert window.HTMLCanvasElement.prototype.getContext === undefined; + +- name: type.replace + desc: HTMLCanvasElement methods can be replaced, and the replacement methods used by canvases + notes: *bindings + testing: + - canvas.type + code: | + window.HTMLCanvasElement.prototype.getContext = function (name) { return 0; }; + @assert canvas.getContext('2d') === 0; + +- name: type.extend + desc: HTMLCanvasElement methods can be added, and the new methods used by canvases + notes: *bindings + testing: + - canvas.type + code: | + window.HTMLCanvasElement.prototype.getZero = function () { return 0; }; + @assert canvas.getZero() === 0; + + +- name: size.attributes.idl.set.zero + desc: Setting width/height IDL attributes to 0 + testing: + - size.width + - size.height + code: | + canvas.width = 0; + canvas.height = 0; + @assert canvas.width === 0; + @assert canvas.height === 0; +# expected: size 0 0 # can't generate zero-sized PNG + +- name: size.attributes.idl + desc: Getting/setting width/height IDL attributes + testing: + - size.width + - size.height + webidl: + - es-unsigned-long + code: | + canvas.width = "100"; + canvas.height = "100"; + @assert canvas.width === 100; + @assert canvas.height === 100; + + canvas.width = "+1.5e2"; + canvas.height = "0x96"; + @assert canvas.width === 150; + @assert canvas.height === 150; + + canvas.width = 200 - Math.pow(2, 32); + canvas.height = 200 - Math.pow(2, 32); + @assert canvas.width === 200; + @assert canvas.height === 200; + + canvas.width = 301.999; + canvas.height = 301.001; + @assert canvas.width === 301; + @assert canvas.height === 301; + + canvas.width = "400x"; + canvas.height = "foo"; + @assert canvas.width === 0; + @assert canvas.height === 0; + +- name: size.attributes.default + desc: Default width/height when attributes are missing + testing: + - size.default + - size.missing + canvas: "" + code: | + @assert canvas.width === 300; + @assert canvas.height === 150; + @assert !canvas.hasAttribute('width'); + @assert !canvas.hasAttribute('height'); + expected: size 300 150 + +- name: size.attributes.reflect.setidl + desc: Setting IDL attributes updates IDL and content attributes + testing: + - size.reflect + code: | + canvas.width = 120; + canvas.height = 60; + @assert canvas.getAttribute('width') === '120'; + @assert canvas.getAttribute('height') === '60'; + @assert canvas.width === 120; + @assert canvas.height === 60; + expected: size 120 60 + +- name: size.attributes.reflect.setidlzero + desc: Setting IDL attributes to 0 updates IDL and content attributes + testing: + - size.reflect + code: | + canvas.width = 0; + canvas.height = 0; + @assert canvas.getAttribute('width') === '0'; + @assert canvas.getAttribute('height') === '0'; + @assert canvas.width === 0; + @assert canvas.height === 0; +# expected: size 0 0 # can't generate zero-sized PNG + +- name: size.attributes.reflect.setcontent + desc: Setting content attributes updates IDL and content attributes + testing: + - size.reflect + code: | + canvas.setAttribute('width', '120'); + canvas.setAttribute('height', '60'); + @assert canvas.getAttribute('width') === '120'; + @assert canvas.getAttribute('height') === '60'; + @assert canvas.width === 120; + @assert canvas.height === 60; + expected: size 120 60 + +- name: size.attributes.removed + desc: Removing content attributes reverts to default size + testing: + - size.missing + canvas: width="120" height="60" + code: | + @assert canvas.width === 120; + canvas.removeAttribute('width'); + @assert canvas.width === 300; + expected: size 300 60 + +- meta: | + cases = [ + ("zero", "0", 0), + ("empty", "", None), + ("onlyspace", " ", None), + ("space", " 100", 100), + ("whitespace", "\n\t\f100", 100), + ("plus", "+100", 100), + ("minus", "-100", None), + ("octal", "0100", 100), + ("hex", "0x100", 0), + ("exp", "100e1", 100), + ("decimal", "100.999", 100), + ("percent", "100%", 100), + ("em", "100em", 100), + ("junk", "#!?", None), + ("trailingjunk", "100#!?", 100), + ] + def gen(name, string, exp, code): + testing = ["size.nonnegativeinteger"] + if exp is None: + testing.append("size.error") + code += "@assert canvas.width === 300;\n@assert canvas.height === 150;\n" + expected = "size 300 150" + else: + code += "@assert canvas.width === %s;\n@assert canvas.height === %s;\n" % (exp, exp) + expected = "size %s %s" % (exp, exp) + + # With "100%", Opera gets canvas.width = 100 but renders at 100% of the frame width, + # so check the CSS display width + code += '@assert window.getComputedStyle(canvas, null).getPropertyValue("width") === "%spx";\n' % (exp, ) + + code += "@assert canvas.getAttribute('width') === %r;\n" % string + code += "@assert canvas.getAttribute('height') === %r;\n" % string + + if exp == 0: + expected = None # can't generate zero-sized PNGs for the expected image + + return code, testing, expected + + for name, string, exp in cases: + code = "" + code, testing, expected = gen(name, string, exp, code) + tests.append( { + "name": "size.attributes.parse.%s" % name, + "desc": "Parsing of non-negative integers", + "testing": testing, + "canvas": 'width="%s" height="%s"' % (string, string), + "code": code, + "expected": expected + } ) + + for name, string, exp in cases: + code = "canvas.setAttribute('width', %r);\ncanvas.setAttribute('height', %r);\n" % (string, string) + code, testing, expected = gen(name, string, exp, code) + tests.append( { + "name": "size.attributes.setAttribute.%s" % name, + "desc": "Parsing of non-negative integers in setAttribute", + "testing": testing, + "canvas": 'width="50" height="50"', + "code": code, + "expected": expected + } ) + +- name: size.attributes.style + desc: Canvas size is independent of CSS resizing + testing: + - size.css + canvas: 'width="50" height="30" style="width: 100px; height: 50px"' + code: | + @assert canvas.width === 50; + @assert canvas.height === 30; + expected: size 100 50 + +- name: size.large + DISABLED: | + "User agents may impose implementation-specific limits on otherwise unconstrained + inputs, e.g. to prevent denial of service attacks, to guard against running out of memory, + or to work around platform-specific limitations." + testing: + - size.width + - size.height + notes: Not sure how reasonable this is, but the spec doesn't say there's an upper limit on the size. + code: | + var n = 2147483647; // 2^31 - 1, which should be supported by any sensible definition of "long" + canvas.width = n; + canvas.height = n; + @assert canvas.width === n; + @assert canvas.height === n; +# expected: size 2147483647 2147483647 # not a good idea to generate the expected image in this case... + +- name: initial.colour + desc: Initial state is transparent black + testing: + - initial.colour + notes: | + Output should be transparent black (not transparent anything-else), but manual + verification can only confirm that it's transparent - it's not possible to make + the actual blackness visible. + code: | + @assert pixel 20,20 == 0,0,0,0; + expected: size 100 50 # transparent + +- name: initial.reset.different + desc: Changing size resets canvas to transparent black + testing: + - initial.reset + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 50, 50); + @assert pixel 20,20 == 255,0,0,255; + canvas.width = 50; + @assert pixel 20,20 == 0,0,0,0; + expected: size 50 50 # transparent + +- name: initial.reset.same + desc: Setting size (not changing the value) resets canvas to transparent black + testing: + - initial.reset + code: | + canvas.width = 100; + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 50, 50); + @assert pixel 20,20 == 255,0,0,255; + canvas.width = 100; + @assert pixel 20,20 == 0,0,0,0; + expected: size 100 50 # transparent + +- name: initial.reset.path + desc: Resetting the canvas state resets the current path + testing: + - initial.reset + code: | + canvas.width = 100; + ctx.rect(0, 0, 100, 50); + canvas.width = 100; + ctx.fillStyle = '#f00'; + ctx.fill(); + @assert pixel 20,20 == 0,0,0,0; + expected: size 100 50 # transparent + +- name: initial.reset.clip + desc: Resetting the canvas state resets the current clip region + testing: + - initial.reset + code: | + canvas.width = 100; + ctx.rect(0, 0, 1, 1); + ctx.clip(); + canvas.width = 100; + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 20,20 == 0,255,0,255; + expected: green + +- name: initial.reset.transform + desc: Resetting the canvas state resets the current transformation matrix + testing: + - initial.reset + code: | + canvas.width = 100; + ctx.scale(0.1, 0.1); + canvas.width = 100; + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 20,20 == 0,255,0,255; + expected: green + +- name: initial.reset.gradient + desc: Resetting the canvas state does not invalidate any existing gradients + testing: + - initial.reset + code: | + canvas.width = 50; + var g = ctx.createLinearGradient(0, 0, 100, 0); + g.addColorStop(0, '#0f0'); + g.addColorStop(1, '#0f0'); + canvas.width = 100; + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: initial.reset.pattern + desc: Resetting the canvas state does not invalidate any existing patterns + testing: + - initial.reset + code: | + canvas.width = 30; + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 30, 50); + var p = ctx.createPattern(canvas, 'repeat-x'); + canvas.width = 100; + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = p; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +# See tests2d.yaml for initial.reset.2dstate + + +- name: context.emptystring + desc: getContext with empty string returns null + testing: + - context.unrecognised + code: | + @assert canvas.getContext("") === null; + +- name: context.unrecognised.badname + desc: getContext with unrecognised context name returns null + testing: + - context.unrecognised + code: | + @assert canvas.getContext('This is not an implemented context in any real browser') === null; + +- name: context.unrecognised.badsuffix + desc: Context name "2d" plus a suffix is unrecognised + testing: + - context.unrecognised + code: | + @assert canvas.getContext("2d#") === null; + +- name: context.unrecognised.nullsuffix + desc: Context name "2d" plus a "\0" suffix is unrecognised + testing: + - context.unrecognised + code: | + @assert canvas.getContext("2d\0") === null; + +- name: context.unrecognised.unicode + desc: Context name which kind of looks like "2d" is unrecognised + testing: + - context.unrecognised + code: | + @assert canvas.getContext("2\uFF44") === null; // Fullwidth Latin Small Letter D + +- name: context.casesensitive + desc: Context name "2D" is unrecognised; matching is case sensitive + testing: + - context.unrecognised + code: | + @assert canvas.getContext('2D') === null; + +- name: context.arguments.missing + notes: *bindings + testing: + - canvas.getContext + code: | + @assert throws TypeError canvas.getContext(); @moz-todo + + + +- name: toBlob.png + desc: toBlob with image/png returns a PNG Blob + testing: + - toBlob.png + code: | + canvas.toBlob(function(data){ + @assert data.type === "image/png"; + }, 'image/png'); + +- name: toBlob.jpeg + desc: toBlob with image/jpeg returns a JPEG Blob + testing: + - toBlob.jpeg + code: | + canvas.toBlob(function(data){ + @assert data.type === "image/jpeg"; + }, 'image/jpeg'); + +- name: toDataURL.default + desc: toDataURL with no arguments returns a PNG + testing: + - toDataURL.noarguments + code: | + var data = canvas.toDataURL(); + @assert data =~ /^data:image\/png[;,]/; + +- name: toDataURL.png + desc: toDataURL with image/png returns a PNG + testing: + - toDataURL.png + - toDataURL.witharguments + code: | + var data = canvas.toDataURL('image/png'); + @assert data =~ /^data:image\/png[;,]/; + +- name: toDataURL.jpg + desc: toDataURL with image/jpg is invalid type hence returns a PNG + testing: + - toDataURL.jpg + - toDataURL.witharguments + code: | + var data = canvas.toDataURL('image/jpg'); + @assert data =~ /^data:image\/png[;,]/; + + +- name: toDataURL.bogustype + desc: toDataURL with a syntactically invalid type returns a PNG + testing: + - toDataURL.unrecognised + code: | + var data = canvas.toDataURL('bogus'); + @assert data =~ /^data:image\/png[;,]/; + +- name: toDataURL.unrecognised + desc: toDataURL with an unhandled type returns a PNG + testing: + - toDataURL.unrecognised + code: | + var data = canvas.toDataURL('image/example'); + @assert data =~ /^data:image\/png[;,]/; + +- name: toDataURL.lowercase.ascii + desc: toDataURL type is case-insensitive + testing: + - toDataURL.lowercase + code: | + var data = canvas.toDataURL('ImAgE/PnG'); + @assert data =~ /^data:image\/png[;,]/; + + // If JPEG is supported at all, it must be supported case-insensitively + data = canvas.toDataURL('image/jpeg'); + if (data.match(/^data:image\/jpeg[;,]/)) { + data = canvas.toDataURL('ImAgE/JpEg'); + @assert data =~ /^data:image\/jpeg[;,]/; + } + +- name: toDataURL.lowercase.unicode + desc: toDataURL type is ASCII-case-insensitive + testing: + - toDataURL.lowercase + code: | + // Use LATIN CAPITAL LETTER I WITH DOT ABOVE (Unicode lowercase is "i") + var data = canvas.toDataURL('\u0130mage/png'); + @assert data =~ /^data:image\/png[;,]/; + + var data = canvas.toDataURL('\u0130mage/jpeg'); + @assert data =~ /^data:image\/png[;,]/; + +- name: toDataURL.arguments.1 + desc: toDataURL ignores extra arguments + testing: + - toDataURL.arguments + code: | + var data = canvas.toDataURL('image/png', 'another argument that should not raise an exception'); + @assert data =~ /^data:image\/png[;,]/; + +- name: toDataURL.arguments.2 + desc: toDataURL ignores extra arguments + testing: + - toDataURL.arguments + code: | + var data = canvas.toDataURL('image/png', 'another argument that should not raise an exception', 'and another'); + @assert data =~ /^data:image\/png[;,]/; + +- name: toDataURL.arguments.3 + desc: toDataURL ignores extra arguments + testing: + - toDataURL.arguments + code: | + // More arguments that should not raise exceptions + var data = canvas.toDataURL('image/png', null, null, null); + @assert data =~ /^data:image\/png[;,]/; + +- name: toDataURL.nocontext + desc: toDataURL works before any context has been got + testing: + - toDataURL.noarguments + code: | + var canvas2 = document.createElement('canvas'); + var data = canvas2.toDataURL(); + @assert data =~ /^data:image\/png[;,]/; + +- name: toDataURL.zerosize + desc: toDataURL on zero-size canvas returns 'data:,' + testing: + - toDataURL.zerosize + canvas: width="0" height="0" + code: | + var data = canvas.toDataURL(); + @assert data === 'data:,'; + +- name: toDataURL.zerowidth + desc: toDataURL on zero-size canvas returns 'data:,' + testing: + - toDataURL.zerosize + canvas: width="0" + code: | + var data = canvas.toDataURL(); + @assert data === 'data:,'; + +- name: toDataURL.zeroheight + desc: toDataURL on zero-size canvas returns 'data:,' + testing: + - toDataURL.zerosize + canvas: height="0" + code: | + var data = canvas.toDataURL(); + @assert data === 'data:,'; + +- name: toDataURL.large1 + DISABLED: just testing implementation limits, and tends to crash + canvas: width="30000" height="1" + code: | + var data = canvas.toDataURL(); + @assert data =~ /^data:image\/png[;,]/; + +- name: toDataURL.large2 + DISABLED: just testing implementation limits, and tends to crash + canvas: width="32767" height="1" + code: | + var data = canvas.toDataURL(); + @assert data =~ /^data:image\/png[;,]/; + +- name: toDataURL.large3 + DISABLED: just testing implementation limits, and tends to crash + canvas: width="32768" height="1" + code: | + var data = canvas.toDataURL(); + @assert data =~ /^data:image\/png[;,]/; + +- name: toDataURL.png.primarycolours + desc: toDataURL with PNG handles simple colours correctly + testing: + - toDataURL.png + code: | + ctx.fillStyle = '#ff0'; + ctx.fillRect(0, 0, 25, 40); + ctx.fillStyle = '#0ff'; + ctx.fillRect(25, 0, 50, 40); + ctx.fillStyle = '#00f'; + ctx.fillRect(75, 0, 25, 40); + ctx.fillStyle = '#fff'; + ctx.fillRect(0, 40, 100, 10); + var data = canvas.toDataURL(); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + var img = new Image(); + deferTest(); + img.onload = t.step_func_done(function () + { + ctx.drawImage(img, 0, 0); + @assert pixel 12,20 == 255,255,0,255; + @assert pixel 50,20 == 0,255,255,255; + @assert pixel 87,20 == 0,0,255,255; + @assert pixel 50,45 == 255,255,255,255; + }); + img.src = data; + expected: | + size 100 50 + cr.set_source_rgb(1, 1, 0) + cr.rectangle(0, 0, 25, 40) + cr.fill() + cr.set_source_rgb(0, 1, 1) + cr.rectangle(25, 0, 50, 40) + cr.fill() + cr.set_source_rgb(0, 0, 1) + cr.rectangle(75, 0, 25, 40) + cr.fill() + cr.set_source_rgb(1, 1, 1) + cr.rectangle(0, 40, 100, 10) + cr.fill() + +- name: toDataURL.png.complexcolours + desc: toDataURL with PNG handles non-primary and non-solid colours correctly + testing: + - toDataURL.png + code: | + // (These values are chosen to survive relatively alright through being premultiplied) + ctx.fillStyle = 'rgba(1, 3, 254, 1)'; + ctx.fillRect(0, 0, 25, 25); + ctx.fillStyle = 'rgba(8, 252, 248, 0.75)'; + ctx.fillRect(25, 0, 25, 25); + ctx.fillStyle = 'rgba(6, 10, 250, 0.502)'; + ctx.fillRect(50, 0, 25, 25); + ctx.fillStyle = 'rgba(12, 16, 244, 0.25)'; + ctx.fillRect(75, 0, 25, 25); + var img = new Image(); + deferTest(); + img.onload = t.step_func_done(function () + { + ctx.drawImage(img, 0, 25); + // (The alpha values do not really survive float->int conversion, so just + // do approximate comparisons) + @assert pixel 12,40 == 1,3,254,255; + @assert pixel 37,40 ==~ 8,252,248,191 +/- 2; + @assert pixel 62,40 ==~ 6,10,250,127 +/- 4; + @assert pixel 87,40 ==~ 12,16,244,63 +/- 8; + }); + img.src = canvas.toDataURL(); + expected: | + size 100 50 + cr.set_source_rgba(1/255., 3/255., 254/255., 1) + cr.rectangle(0, 0, 25, 50) + cr.fill() + cr.set_source_rgba(8/255., 252/255., 248/255., 191/255.) + cr.rectangle(25, 0, 25, 50) + cr.fill() + cr.set_source_rgba(6/255., 10/255., 250/255., 127/255.) + cr.rectangle(50, 0, 25, 50) + cr.fill() + cr.set_source_rgba(12/255., 16/255., 244/255., 63/255.) + cr.rectangle(75, 0, 25, 50) + cr.fill() + +- name: toDataURL.jpeg.primarycolours + desc: toDataURL with JPEG handles simple colours correctly + testing: + - toDataURL.jpeg + code: | + ctx.fillStyle = '#ff0'; + ctx.fillRect(0, 0, 25, 40); + ctx.fillStyle = '#0ff'; + ctx.fillRect(25, 0, 50, 40); + ctx.fillStyle = '#00f'; + ctx.fillRect(75, 0, 25, 40); + ctx.fillStyle = '#fff'; + ctx.fillRect(0, 40, 100, 10); + var data = canvas.toDataURL('image/jpeg'); // it is okay if this returns a PNG instead + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + var img = new Image(); + deferTest(); + img.onload = t.step_func_done(function () + { + ctx.drawImage(img, 0, 0); + @assert pixel 12,20 ==~ 255,255,0,255 +/- 8; + @assert pixel 50,20 ==~ 0,255,255,255 +/- 8; + @assert pixel 87,20 ==~ 0,0,255,255 +/- 8; + @assert pixel 50,45 ==~ 255,255,255,255 +/- 8; + }); + img.src = data; + expected: | + size 100 50 + cr.set_source_rgb(1, 1, 0) + cr.rectangle(0, 0, 25, 40) + cr.fill() + cr.set_source_rgb(0, 1, 1) + cr.rectangle(25, 0, 50, 40) + cr.fill() + cr.set_source_rgb(0, 0, 1) + cr.rectangle(75, 0, 25, 40) + cr.fill() + cr.set_source_rgb(1, 1, 1) + cr.rectangle(0, 40, 100, 10) + cr.fill() + +- name: toDataURL.jpeg.alpha + desc: toDataURL with JPEG composites onto black + testing: + - toDataURL.jpeg + - toDataURL.noalpha + code: | + ctx.fillStyle = 'rgba(128, 255, 128, 0.5)'; + ctx.fillRect(0, 0, 100, 50); + ctx.globalCompositeOperation = 'destination-over'; // should be ignored by toDataURL + var data = canvas.toDataURL('image/jpeg'); + ctx.globalCompositeOperation = 'source-over'; + if (!data.match(/^data:image\/jpeg[;,]/)) { + @assert true; + } else { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + var img = new Image(); + deferTest(); + img.onload = t.step_func_done(function () + { + ctx.drawImage(img, 0, 0); + @assert pixel 50,25 ==~ 63,127,63,255 +/- 8; + }); + img.src = data; + } + expected: | + size 100 50 + cr.set_source_rgb(0.25, 0.5, 0.25) + cr.rectangle(0, 0, 100, 50) + cr.fill() + +- name: toDataURL.jpeg.quality.basic + desc: toDataURL with JPEG uses the quality parameter + testing: + - toDataURL.jpeg.quality + mozilla: { throws } + code: | + ctx.fillStyle = '#00f'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0ff'; + ctx.fillRect(0, 3, 100, 1); + // Check for JPEG support first + var data = canvas.toDataURL('image/jpeg'); + if (!data.match(/^data:image\/jpeg[;,]/)) { + @assert true; + } else { + var data_hi = canvas.toDataURL('image/jpeg', 0.99); + var data_lo = canvas.toDataURL('image/jpeg', 0.01); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + deferTest(); + var img_hi = new Image(); + img_hi.onload = function () + { + var img_lo = new Image(); + img_lo.onload = t.step_func_done(function () + { + ctx.drawImage(img_hi, 0, 0, 50, 50, 0, 0, 50, 50); + ctx.drawImage(img_lo, 0, 0, 50, 50, 50, 0, 50, 50); + @assert data_hi.length > data_lo.length; + @assert pixel 25,25 ==~ 0,0,255,255 +/- 8; + @assert pixel 75,25 ==~ 0,0,255,255 +/- 32; + }); + img_lo.src = data_lo; + }; + img_hi.src = data_hi; + } + expected: | + size 100 50 + cr.set_source_rgb(0, 0, 1) + cr.rectangle(0, 0, 100, 50) + cr.fill() + cr.set_source_rgb(0, 1, 1) + cr.rectangle(0, 3, 100, 1) + cr.fill() + +- name: toDataURL.jpeg.quality.notnumber + desc: toDataURL with JPEG handles non-numeric quality parameters + testing: + - toDataURL.jpeg.nan + code: | + ctx.fillStyle = '#00f'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0ff'; + ctx.fillRect(0, 3, 100, 1); + // Check for JPEG support first + var data = canvas.toDataURL('image/jpeg'); + if (!data.match(/^data:image\/jpeg[;,]/)) { + @assert true; + } else { + @assert canvas.toDataURL('image/jpeg', 'bogus') === data; + @assert canvas.toDataURL('image/jpeg', {}) === data; + @assert canvas.toDataURL('image/jpeg', null) === data; + @assert canvas.toDataURL('image/jpeg', undefined) === data; + @assert canvas.toDataURL('image/jpeg', true) === data; + @assert canvas.toDataURL('image/jpeg', '0.01') === data; + } + +- name: toDataURL.jpeg.quality.outsiderange + desc: toDataURL with JPEG handles out-of-range quality parameters + testing: + - toDataURL.jpeg.range + code: | + ctx.fillStyle = '#00f'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0ff'; + ctx.fillRect(0, 3, 100, 1); + // Check for JPEG support first + var data = canvas.toDataURL('image/jpeg'); + if (!data.match(/^data:image\/jpeg[;,]/)) { + @assert true; + } else { + @assert canvas.toDataURL('image/jpeg', 10) === data; + @assert canvas.toDataURL('image/jpeg', -10) === data; + @assert canvas.toDataURL('image/jpeg', 1.01) === data; + @assert canvas.toDataURL('image/jpeg', -0.01) === data; + + @assert canvas.toDataURL('image/jpeg', 1).length >= canvas.toDataURL('image/jpeg', 0.9).length; + @assert canvas.toDataURL('image/jpeg', 0).length <= canvas.toDataURL('image/jpeg', 0.1).length; + } + + +# TODO: work out what security exception should be thrown +# TODO: test same-origin vs same-host + +- name: security.drawImage.image + desc: drawImage of different-origin image makes the canvas origin-unclean + mozilla: { disabled } # relies on external resources + testing: + - security.drawImage.image + - security.toDataURL + - security.getImageData + scripts: + - /common/get-host-info.sub.js + - data:text/javascript,addCrossOriginYellowImage() + code: | + ctx.drawImage(document.getElementById('yellow.png'), 0, 0); + @assert throws SECURITY_ERR canvas.toDataURL(); + @assert throws SECURITY_ERR ctx.getImageData(0, 0, 1, 1); + +- name: security.drawImage.canvas + desc: drawImage of unclean canvas makes the canvas origin-unclean + mozilla: { disabled } # relies on external resources + testing: + - security.drawImage.canvas + scripts: + - /common/get-host-info.sub.js + - data:text/javascript,addCrossOriginYellowImage() + code: | + var canvas2 = document.createElement('canvas'); + canvas2.width = 100; + canvas2.height = 50; + var ctx2 = canvas2.getContext('2d'); + ctx2.drawImage(document.getElementById('yellow.png'), 0, 0); + ctx.drawImage(canvas2, 0, 0); + @assert throws SECURITY_ERR canvas.toDataURL(); + @assert throws SECURITY_ERR ctx.getImageData(0, 0, 1, 1); + +- name: security.pattern.create + desc: Creating an unclean pattern does not make the canvas origin-unclean + mozilla: { disabled } # relies on external resources + testing: + - security.start + scripts: + - /common/get-host-info.sub.js + - data:text/javascript,addCrossOriginYellowImage() + code: | + var p = ctx.createPattern(document.getElementById('yellow.png'), 'repeat'); + canvas.toDataURL(); + ctx.getImageData(0, 0, 1, 1); + @assert true; // okay if there was no exception + +- name: security.pattern.cross + desc: Using an unclean pattern makes the target canvas origin-unclean, not the pattern canvas + mozilla: { disabled } # relies on external resources + testing: + - security.start + scripts: + - /common/get-host-info.sub.js + - data:text/javascript,addCrossOriginYellowImage() + code: | + var canvas2 = document.createElement('canvas'); + canvas2.width = 100; + canvas2.height = 50; + var ctx2 = canvas2.getContext('2d'); + var p = ctx2.createPattern(document.getElementById('yellow.png'), 'repeat'); + ctx.fillStyle = p; + ctx.fillRect(0, 0, 100, 50); + @assert throws SECURITY_ERR canvas.toDataURL(); + @assert throws SECURITY_ERR ctx.getImageData(0, 0, 1, 1); + canvas2.toDataURL(); + ctx2.getImageData(0, 0, 1, 1); + +- name: security.pattern.canvas.timing + desc: Pattern safety depends on whether the source was origin-clean, not on whether it still is clean + notes: Disagrees with spec on "is" vs "was" + mozilla: { disabled } # relies on external resources + testing: + - security.start + - security.fillStyle.canvas + scripts: + - /common/get-host-info.sub.js + - data:text/javascript,addCrossOriginYellowImage() + code: | + var canvas2 = document.createElement('canvas'); + canvas2.width = 100; + canvas2.height = 50; + var ctx2 = canvas2.getContext('2d'); + ctx2.fillStyle = '#0f0'; + ctx2.fillRect(0, 0, 100, 50); + var p = ctx.createPattern(canvas2, 'repeat'); + ctx2.drawImage(document.getElementById('yellow.png'), 0, 0); // make canvas2 origin-unclean + ctx.fillStyle = p; + ctx.fillRect(0, 0, 100, 50); + canvas.toDataURL(); + ctx.getImageData(0, 0, 1, 1); + @assert true; // okay if there was no exception + +- name: security.pattern.image.fillStyle + desc: Setting fillStyle to a pattern of a different-origin image makes the canvas origin-unclean + mozilla: { disabled } # relies on external resources + testing: + - security.fillStyle.image + scripts: + - /common/get-host-info.sub.js + - data:text/javascript,addCrossOriginYellowImage() + code: | + var p = ctx.createPattern(document.getElementById('yellow.png'), 'repeat'); + ctx.fillStyle = p; + ctx.fillStyle = 'red'; + @assert throws SECURITY_ERR canvas.toDataURL(); + @assert throws SECURITY_ERR ctx.getImageData(0, 0, 1, 1); + +- name: security.pattern.canvas.fillStyle + desc: Setting fillStyle to a pattern of an unclean canvas makes the canvas origin-unclean + mozilla: { bug: 354127, disabled } # relies on external resources + testing: + - security.fillStyle.canvas + scripts: + - /common/get-host-info.sub.js + - data:text/javascript,addCrossOriginYellowImage() + code: | + var canvas2 = document.createElement('canvas'); + canvas2.width = 100; + canvas2.height = 50; + var ctx2 = canvas2.getContext('2d'); + ctx2.drawImage(document.getElementById('yellow.png'), 0, 0); + var p = ctx.createPattern(canvas2, 'repeat'); + ctx.fillStyle = p; + ctx.fillStyle = 'red'; + @assert throws SECURITY_ERR canvas.toDataURL(); + @assert throws SECURITY_ERR ctx.getImageData(0, 0, 1, 1); + +- name: security.pattern.image.strokeStyle + desc: Setting strokeStyle to a pattern of a different-origin image makes the canvas origin-unclean + mozilla: { disabled } # relies on external resources + testing: + - security.strokeStyle.image + scripts: + - /common/get-host-info.sub.js + - data:text/javascript,addCrossOriginYellowImage() + code: | + var p = ctx.createPattern(document.getElementById('yellow.png'), 'repeat'); + ctx.strokeStyle = p; + ctx.strokeStyle = 'red'; + @assert throws SECURITY_ERR canvas.toDataURL(); + @assert throws SECURITY_ERR ctx.getImageData(0, 0, 1, 1); + +- name: security.pattern.canvas.strokeStyle + desc: Setting strokeStyle to a pattern of an unclean canvas makes the canvas origin-unclean + mozilla: { bug: 354127, disabled } # relies on external resources + testing: + - security.strokeStyle.canvas + scripts: + - /common/get-host-info.sub.js + - data:text/javascript,addCrossOriginYellowImage() + code: | + var canvas2 = document.createElement('canvas'); + canvas2.width = 100; + canvas2.height = 50; + var ctx2 = canvas2.getContext('2d'); + ctx2.drawImage(document.getElementById('yellow.png'), 0, 0); + var p = ctx.createPattern(canvas2, 'repeat'); + ctx.strokeStyle = p; + ctx.strokeStyle = 'red'; + @assert throws SECURITY_ERR canvas.toDataURL(); + @assert throws SECURITY_ERR ctx.getImageData(0, 0, 1, 1); + +- name: security.dataURI + desc: 'data: URIs do not count as different-origin, and do not taint the canvas' + mozilla: { disabled, bug: 417836 } # can't do "todo" so just disable it + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + var data = canvas.toDataURL(); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + var img = new Image(); + deferTest(); + img.onload = t.step_func_done(function () + { + ctx.drawImage(img, 0, 0); + canvas.toDataURL(); // should be permitted + @assert pixel 50,25 == 0,255,0,255; + }); + img.src = data; + expected: green + +- name: security.reset + desc: Resetting the canvas state does not reset the origin-clean flag + mozilla: { disabled } # relies on external resources + testing: + - initial.reset + scripts: + - /common/get-host-info.sub.js + - data:text/javascript,addCrossOriginYellowImage() + code: | + canvas.width = 50; + ctx.drawImage(document.getElementById('yellow.png'), 0, 0); + @assert throws SECURITY_ERR canvas.toDataURL(); + canvas.width = 100; + @assert throws SECURITY_ERR canvas.toDataURL(); diff --git a/testing/web-platform/tests/2dcontext/tools/tests2d.yaml b/testing/web-platform/tests/2dcontext/tools/tests2d.yaml new file mode 100644 index 000000000..21a8c0015 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/tools/tests2d.yaml @@ -0,0 +1,10092 @@ +# Copyright (c) 2011 Philip Taylor +# Released under the BSD license and W3C Test Suite License: see LICENSE.txt + +- name: 2d.getcontext.exists + desc: The 2D context is implemented + testing: + - context.2d + code: | + @assert canvas.getContext('2d') !== null; + +- name: 2d.getcontext.extraargs + desc: The 2D context ignores extra getContext arguments + testing: + - context.2d.extraargs + code: | + @assert canvas.getContext('2d', false, {}, [], 1, "2") !== null; + +- name: 2d.type.exists + desc: The 2D context interface is a property of 'window' + notes: &bindings Defined in "Web IDL" (draft) + testing: + - context.2d.type + code: | + @assert window.CanvasRenderingContext2D; + +- name: 2d.type.delete + desc: window.CanvasRenderingContext2D is Configurable + notes: *bindings + testing: + - context.2d.type + code: | + @assert window.CanvasRenderingContext2D !== undefined; + @assert delete window.CanvasRenderingContext2D === true; + @assert window.CanvasRenderingContext2D === undefined; + +- name: 2d.type.prototype + desc: window.CanvasRenderingContext2D.prototype are not [[Writable]] and not [[Configurable]], and its methods are [[Configurable]]. + notes: *bindings + testing: + - context.2d.type + code: | + @assert window.CanvasRenderingContext2D.prototype; + @assert window.CanvasRenderingContext2D.prototype.fill; + window.CanvasRenderingContext2D.prototype = null; + @assert window.CanvasRenderingContext2D.prototype; + delete window.CanvasRenderingContext2D.prototype; + @assert window.CanvasRenderingContext2D.prototype; + window.CanvasRenderingContext2D.prototype.fill = 1; + @assert window.CanvasRenderingContext2D.prototype.fill === 1; + delete window.CanvasRenderingContext2D.prototype.fill; + @assert window.CanvasRenderingContext2D.prototype.fill === undefined; + +- name: 2d.type.replace + desc: Interface methods can be overridden + notes: *bindings + testing: + - context.2d.type + code: | + var fillRect = window.CanvasRenderingContext2D.prototype.fillRect; + window.CanvasRenderingContext2D.prototype.fillRect = function (x, y, w, h) + { + this.fillStyle = '#0f0'; + fillRect.call(this, x, y, w, h); + }; + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.type.extend + desc: Interface methods can be added + notes: *bindings + testing: + - context.2d.type + code: | + window.CanvasRenderingContext2D.prototype.fillRectGreen = function (x, y, w, h) + { + this.fillStyle = '#0f0'; + this.fillRect(x, y, w, h); + }; + ctx.fillStyle = '#f00'; + ctx.fillRectGreen(0, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.getcontext.unique + desc: getContext('2d') returns the same object + testing: + - context.unique + code: | + @assert canvas.getContext('2d') === canvas.getContext('2d'); + +- name: 2d.getcontext.shared + desc: getContext('2d') returns objects which share canvas state + testing: + - context.unique + code: | + var ctx2 = canvas.getContext('2d'); + ctx.fillStyle = '#f00'; + ctx2.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.voidreturn + desc: void methods return undefined + notes: *bindings + images: + - yellow.png + code: | + @assert ctx.save() === undefined; + @assert ctx.restore() === undefined; + @assert ctx.scale(1, 1) === undefined; + @assert ctx.rotate(0) === undefined; + @assert ctx.translate(0, 0) === undefined; + if (ctx.transform) { // (avoid spurious failures, since the aim here is not to test that all features are supported) + @assert ctx.transform(1, 0, 0, 1, 0, 0) === undefined; + } + if (ctx.setTransform) { + @assert ctx.setTransform(1, 0, 0, 1, 0, 0) === undefined; + } + @assert ctx.clearRect(0, 0, 0, 0) === undefined; + @assert ctx.fillRect(0, 0, 0, 0) === undefined; + @assert ctx.strokeRect(0, 0, 0, 0) === undefined; + @assert ctx.beginPath() === undefined; + @assert ctx.closePath() === undefined; + @assert ctx.moveTo(0, 0) === undefined; + @assert ctx.lineTo(0, 0) === undefined; + @assert ctx.quadraticCurveTo(0, 0, 0, 0) === undefined; + @assert ctx.bezierCurveTo(0, 0, 0, 0, 0, 0) === undefined; + @assert ctx.arcTo(0, 0, 0, 0, 1) === undefined; + @assert ctx.rect(0, 0, 0, 0) === undefined; + @assert ctx.arc(0, 0, 1, 0, 0, true) === undefined; + @assert ctx.fill() === undefined; + @assert ctx.stroke() === undefined; + @assert ctx.clip() === undefined; + if (ctx.fillText) { + @assert ctx.fillText('test', 0, 0) === undefined; + @assert ctx.strokeText('test', 0, 0) === undefined; + } + if (ctx.putImageData) { + @assert ctx.putImageData(ctx.getImageData(0, 0, 1, 1), 0, 0) === undefined; + } + @assert ctx.drawImage(document.getElementById('yellow.png'), 0, 0, 1, 1, 0, 0, 0, 0) === undefined; + @assert ctx.drawImage(canvas, 0, 0, 1, 1, 0, 0, 0, 0) === undefined; + @assert ctx.createLinearGradient(0, 0, 0, 0).addColorStop(0, 'white') === undefined; + +- name: 2d.missingargs + desc: Missing arguments cause TypeError + code: | + @assert throws TypeError ctx.scale(); + @assert throws TypeError ctx.scale(1); + @assert throws TypeError ctx.rotate(); + @assert throws TypeError ctx.translate(); + @assert throws TypeError ctx.translate(0); + if (ctx.transform) { // (avoid spurious failures, since the aim here is not to test that all features are supported) + @assert throws TypeError ctx.transform(); + @assert throws TypeError ctx.transform(1); + @assert throws TypeError ctx.transform(1, 0); + @assert throws TypeError ctx.transform(1, 0, 0); + @assert throws TypeError ctx.transform(1, 0, 0, 1); + @assert throws TypeError ctx.transform(1, 0, 0, 1, 0); + } + if (ctx.setTransform) { + @assert throws TypeError ctx.setTransform(); + @assert throws TypeError ctx.setTransform(1); + @assert throws TypeError ctx.setTransform(1, 0); + @assert throws TypeError ctx.setTransform(1, 0, 0); + @assert throws TypeError ctx.setTransform(1, 0, 0, 1); + @assert throws TypeError ctx.setTransform(1, 0, 0, 1, 0); + } + @assert throws TypeError ctx.createLinearGradient(); + @assert throws TypeError ctx.createLinearGradient(0); + @assert throws TypeError ctx.createLinearGradient(0, 0); + @assert throws TypeError ctx.createLinearGradient(0, 0, 1); + @assert throws TypeError ctx.createRadialGradient(); + @assert throws TypeError ctx.createRadialGradient(0); + @assert throws TypeError ctx.createRadialGradient(0, 0); + @assert throws TypeError ctx.createRadialGradient(0, 0, 1); + @assert throws TypeError ctx.createRadialGradient(0, 0, 1, 0); + @assert throws TypeError ctx.createRadialGradient(0, 0, 1, 0, 0); + @assert throws TypeError ctx.createPattern(canvas); + @assert throws TypeError ctx.clearRect(); + @assert throws TypeError ctx.clearRect(0); + @assert throws TypeError ctx.clearRect(0, 0); + @assert throws TypeError ctx.clearRect(0, 0, 0); + @assert throws TypeError ctx.fillRect(); + @assert throws TypeError ctx.fillRect(0); + @assert throws TypeError ctx.fillRect(0, 0); + @assert throws TypeError ctx.fillRect(0, 0, 0); + @assert throws TypeError ctx.strokeRect(); + @assert throws TypeError ctx.strokeRect(0); + @assert throws TypeError ctx.strokeRect(0, 0); + @assert throws TypeError ctx.strokeRect(0, 0, 0); + @assert throws TypeError ctx.moveTo(); + @assert throws TypeError ctx.moveTo(0); + @assert throws TypeError ctx.lineTo(); + @assert throws TypeError ctx.lineTo(0); + @assert throws TypeError ctx.quadraticCurveTo(); + @assert throws TypeError ctx.quadraticCurveTo(0); + @assert throws TypeError ctx.quadraticCurveTo(0, 0); + @assert throws TypeError ctx.quadraticCurveTo(0, 0, 0); + @assert throws TypeError ctx.bezierCurveTo(); + @assert throws TypeError ctx.bezierCurveTo(0); + @assert throws TypeError ctx.bezierCurveTo(0, 0); + @assert throws TypeError ctx.bezierCurveTo(0, 0, 0); + @assert throws TypeError ctx.bezierCurveTo(0, 0, 0, 0); + @assert throws TypeError ctx.bezierCurveTo(0, 0, 0, 0, 0); + @assert throws TypeError ctx.arcTo(); + @assert throws TypeError ctx.arcTo(0); + @assert throws TypeError ctx.arcTo(0, 0); + @assert throws TypeError ctx.arcTo(0, 0, 0); + @assert throws TypeError ctx.arcTo(0, 0, 0, 0); + @assert throws TypeError ctx.rect(); + @assert throws TypeError ctx.rect(0); + @assert throws TypeError ctx.rect(0, 0); + @assert throws TypeError ctx.rect(0, 0, 0); + @assert throws TypeError ctx.arc(); + @assert throws TypeError ctx.arc(0); + @assert throws TypeError ctx.arc(0, 0); + @assert throws TypeError ctx.arc(0, 0, 1); + @assert throws TypeError ctx.arc(0, 0, 1, 0); + // (6th argument to arc is optional) + if (ctx.isPointInPath) { + @assert throws TypeError ctx.isPointInPath(); + @assert throws TypeError ctx.isPointInPath(0); + } + if (ctx.drawFocusRing) { + @assert throws TypeError ctx.drawFocusRing(); + @assert throws TypeError ctx.drawFocusRing(canvas); + @assert throws TypeError ctx.drawFocusRing(canvas, 0); + } + if (ctx.fillText) { + @assert throws TypeError ctx.fillText(); + @assert throws TypeError ctx.fillText('test'); + @assert throws TypeError ctx.fillText('test', 0); + @assert throws TypeError ctx.strokeText(); + @assert throws TypeError ctx.strokeText('test'); + @assert throws TypeError ctx.strokeText('test', 0); + @assert throws TypeError ctx.measureText(); + } + @assert throws TypeError ctx.drawImage(); + @assert throws TypeError ctx.drawImage(canvas); + @assert throws TypeError ctx.drawImage(canvas, 0); + // TODO: n >= 3 args on drawImage could be either a valid overload, + // or too few for another overload, or too many for another + // overload - what should happen? + if (ctx.createImageData) { + @assert throws TypeError ctx.createImageData(); + @assert throws TypeError ctx.createImageData(1); + } + if (ctx.getImageData) { + @assert throws TypeError ctx.getImageData(); + @assert throws TypeError ctx.getImageData(0); + @assert throws TypeError ctx.getImageData(0, 0); + @assert throws TypeError ctx.getImageData(0, 0, 1); + } + if (ctx.putImageData) { + var imgdata = ctx.getImageData(0, 0, 1, 1); + @assert throws TypeError ctx.putImageData(); + @assert throws TypeError ctx.putImageData(imgdata); + @assert throws TypeError ctx.putImageData(imgdata, 0); + } + var g = ctx.createLinearGradient(0, 0, 0, 0); + @assert throws TypeError g.addColorStop(); @moz-todo + @assert throws TypeError g.addColorStop(0); @moz-todo + +- name: 2d.coordinatespace + desc: Coordinate space goes from top-left to bottom-right + notes: This should not be upside down. + manual: We can't tell that getPixelData isn't using the wrong coordinate space too. + testing: + - 2d.coordinatespace + code: | + ctx.fillStyle = '#00f'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0ff'; + ctx.fillRect(0, 0, 50, 25); + @assert pixel 25,12 == 0,255,255,255; + @assert pixel 75,12 == 0,0,255,255; + @assert pixel 25,37 == 0,0,255,255; + @assert pixel 75,37 == 0,0,255,255; + expected: | + size 100 50 + cr.set_source_rgb(0, 0, 1) + cr.rectangle(0, 0, 100, 50) + cr.fill() + cr.set_source_rgb(0, 1, 1) + cr.rectangle(0, 0, 50, 25) + cr.fill() + +- name: 2d.scaled + desc: CSS-scaled canvases get drawn correctly + canvas: 'width="50" height="25" style="width: 100px; height: 50px"' + manual: + code: | + ctx.fillStyle = '#00f'; + ctx.fillRect(0, 0, 50, 25); + ctx.fillStyle = '#0ff'; + ctx.fillRect(0, 0, 25, 10); + expected: | + size 100 50 + cr.set_source_rgb(0, 0, 1) + cr.rectangle(0, 0, 100, 50) + cr.fill() + cr.set_source_rgb(0, 1, 1) + cr.rectangle(0, 0, 50, 20) + cr.fill() + +- name: 2d.canvas.reference + desc: CanvasRenderingContext2D.canvas refers back to its canvas + testing: + - 2d.canvas + code: | + @assert ctx.canvas === canvas; + +- name: 2d.canvas.readonly + desc: CanvasRenderingContext2D.canvas is readonly + testing: + - 2d.canvas.attribute + code: | + var c = document.createElement('canvas'); + var d = ctx.canvas; + @assert c !== d; + ctx.canvas = c; + @assert ctx.canvas === d; + +- meta: | + state = [ # some non-default values to test with + ('strokeStyle', '"#ff0000"'), + ('fillStyle', '"#ff0000"'), + ('globalAlpha', 0.5), + ('lineWidth', 0.5), + ('lineCap', '"round"'), + ('lineJoin', '"round"'), + ('miterLimit', 0.5), + ('shadowOffsetX', 5), + ('shadowOffsetY', 5), + ('shadowBlur', 5), + ('shadowColor', '"#ff0000"'), + ('globalCompositeOperation', '"copy"'), + ('font', '"25px serif"'), + ('textAlign', '"center"'), + ('textBaseline', '"bottom"'), + ] + for key,value in state: + tests.append( { + 'name': '2d.state.saverestore.%s' % key, + 'desc': 'save()/restore() works for %s' % key, + 'testing': [ '2d.state.%s' % key ], + 'code': + """// Test that restore() undoes any modifications + var old = ctx.%(key)s; + ctx.save(); + ctx.%(key)s = %(value)s; + ctx.restore(); + @assert ctx.%(key)s === old; + + // Also test that save() doesn't modify the values + ctx.%(key)s = %(value)s; + old = ctx.%(key)s; + // we're not interested in failures caused by get(set(x)) != x (e.g. + // from rounding), so compare against 'old' instead of against %(value)s + ctx.save(); + @assert ctx.%(key)s === old; + ctx.restore(); + """ % { 'key':key, 'value':value } + } ) + + tests.append( { + 'name': 'initial.reset.2dstate', + 'desc': 'Resetting the canvas state resets 2D state variables', + 'testing': [ 'initial.reset' ], + 'code': + """canvas.width = 100; + var default_val; + """ + "".join( + """ + default_val = ctx.%(key)s; + ctx.%(key)s = %(value)s; + canvas.width = 100; + @assert ctx.%(key)s === default_val; + """ % { 'key':key, 'value':value } + for key,value in state), + } ) + +- name: 2d.state.saverestore.transformation + desc: save()/restore() affects the current transformation matrix + testing: + - 2d.state.transformation + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.save(); + ctx.translate(200, 0); + ctx.restore(); + ctx.fillStyle = '#f00'; + ctx.fillRect(-200, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.state.saverestore.clip + desc: save()/restore() affects the clipping path + testing: + - 2d.state.clip + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.save(); + ctx.rect(0, 0, 1, 1); + ctx.clip(); + ctx.restore(); + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.state.saverestore.path + desc: save()/restore() does not affect the current path + testing: + - 2d.state.path + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.save(); + ctx.rect(0, 0, 100, 50); + ctx.restore(); + ctx.fillStyle = '#0f0'; + ctx.fill(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.state.saverestore.bitmap + desc: save()/restore() does not affect the current bitmap + testing: + - 2d.state.bitmap + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.save(); + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.restore(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.state.saverestore.stack + desc: save()/restore() can be nested as a stack + testing: + - 2d.state.save + - 2d.state.restore + code: | + ctx.lineWidth = 1; + ctx.save(); + ctx.lineWidth = 2; + ctx.save(); + ctx.lineWidth = 3; + @assert ctx.lineWidth === 3; + ctx.restore(); + @assert ctx.lineWidth === 2; + ctx.restore(); + @assert ctx.lineWidth === 1; + +- name: 2d.state.saverestore.stackdepth + desc: save()/restore() stack depth is not unreasonably limited + testing: + - 2d.state.save + - 2d.state.restore + code: | + var limit = 512; + for (var i = 1; i < limit; ++i) + { + ctx.save(); + ctx.lineWidth = i; + } + for (var i = limit-1; i > 0; --i) + { + @assert ctx.lineWidth === i; + ctx.restore(); + } + +- name: 2d.state.saverestore.underflow + desc: restore() with an empty stack has no effect + testing: + - 2d.state.restore.underflow + code: | + for (var i = 0; i < 16; ++i) + ctx.restore(); + ctx.lineWidth = 0.5; + ctx.restore(); + @assert ctx.lineWidth === 0.5; + + +- name: 2d.transformation.order + desc: Transformations are applied in the right order + testing: + - 2d.transformation.order + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.scale(2, 1); + ctx.rotate(Math.PI / 2); + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, -50, 50, 50); + @assert pixel 75,25 == 0,255,0,255; + expected: green + + +- name: 2d.transformation.scale.basic + desc: scale() works + testing: + - 2d.transformation.scale + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.scale(2, 4); + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 50, 12.5); + @assert pixel 90,40 == 0,255,0,255; + expected: green + +- name: 2d.transformation.scale.zero + desc: scale() with a scale factor of zero works + testing: + - 2d.transformation.scale + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.save(); + ctx.translate(50, 0); + ctx.scale(0, 1); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.restore(); + + ctx.save(); + ctx.translate(0, 25); + ctx.scale(1, 0); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.restore(); + + canvas.toDataURL(); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.transformation.scale.negative + desc: scale() with negative scale factors works + testing: + - 2d.transformation.scale + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.save(); + ctx.scale(-1, 1); + ctx.fillStyle = '#0f0'; + ctx.fillRect(-50, 0, 50, 50); + ctx.restore(); + + ctx.save(); + ctx.scale(1, -1); + ctx.fillStyle = '#0f0'; + ctx.fillRect(50, -50, 50, 50); + ctx.restore(); + @assert pixel 25,25 == 0,255,0,255; + @assert pixel 75,25 == 0,255,0,255; + expected: green + +- name: 2d.transformation.scale.large + desc: scale() with large scale factors works + notes: Not really that large at all, but it hits the limits in Firefox. + testing: + - 2d.transformation.scale + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.scale(1e5, 1e5); + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 1, 1); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.transformation.scale.nonfinite + desc: scale() with Infinity/NaN is ignored + testing: + - 2d.nonfinite + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.translate(100, 10); + @nonfinite ctx.scale(<0.1 Infinity -Infinity NaN>, <0.1 Infinity -Infinity NaN>); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(-100, -10, 100, 50); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.transformation.scale.multiple + desc: Multiple scale()s combine + testing: + - 2d.transformation.scale.multiple + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.scale(Math.sqrt(2), Math.sqrt(2)); + ctx.scale(Math.sqrt(2), Math.sqrt(2)); + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 50, 25); + @assert pixel 90,40 == 0,255,0,255; + expected: green + + +- name: 2d.transformation.rotate.zero + desc: rotate() by 0 does nothing + testing: + - 2d.transformation.rotate + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.rotate(0); + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.transformation.rotate.radians + desc: rotate() uses radians + testing: + - 2d.transformation.rotate.radians + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.rotate(Math.PI); // should fail obviously if this is 3.1 degrees + ctx.fillStyle = '#0f0'; + ctx.fillRect(-100, -50, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.transformation.rotate.direction + desc: rotate() is clockwise + testing: + - 2d.transformation.rotate.direction + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.rotate(Math.PI / 2); + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, -100, 50, 100); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.transformation.rotate.wrap + desc: rotate() wraps large positive values correctly + testing: + - 2d.transformation.rotate + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.rotate(Math.PI * (1 + 4096)); // == pi (mod 2*pi) + // We need about pi +/- 0.001 in order to get correct-looking results + // 32-bit floats can store pi*4097 with precision 2^-10, so that should + // be safe enough on reasonable implementations + ctx.fillStyle = '#0f0'; + ctx.fillRect(-100, -50, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,2 == 0,255,0,255; + @assert pixel 98,47 == 0,255,0,255; + expected: green + +- name: 2d.transformation.rotate.wrapnegative + desc: rotate() wraps large negative values correctly + testing: + - 2d.transformation.rotate + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.rotate(-Math.PI * (1 + 4096)); + ctx.fillStyle = '#0f0'; + ctx.fillRect(-100, -50, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,2 == 0,255,0,255; + @assert pixel 98,47 == 0,255,0,255; + expected: green + +- name: 2d.transformation.rotate.nonfinite + desc: rotate() with Infinity/NaN is ignored + testing: + - 2d.nonfinite + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.translate(100, 10); + @nonfinite ctx.rotate(<0.1 Infinity -Infinity NaN>); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(-100, -10, 100, 50); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.transformation.translate.basic + desc: translate() works + testing: + - 2d.transformation.translate + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.translate(100, 50); + ctx.fillStyle = '#0f0'; + ctx.fillRect(-100, -50, 100, 50); + @assert pixel 90,40 == 0,255,0,255; + expected: green + +- name: 2d.transformation.translate.nonfinite + desc: translate() with Infinity/NaN is ignored + testing: + - 2d.nonfinite + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.translate(100, 10); + @nonfinite ctx.translate(<0.1 Infinity -Infinity NaN>, <0.1 Infinity -Infinity NaN>); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(-100, -10, 100, 50); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + + +- name: 2d.transformation.transform.identity + desc: transform() with the identity matrix does nothing + testing: + - 2d.transformation.transform + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.transform(1,0, 0,1, 0,0); + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.transformation.transform.skewed + desc: transform() with skewy matrix transforms correctly + testing: + - 2d.transformation.transform + code: | + // Create green with a red square ring inside it + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.fillRect(20, 10, 60, 30); + ctx.fillStyle = '#0f0'; + ctx.fillRect(40, 20, 20, 10); + + // Draw a skewed shape to fill that gap, to make sure it is aligned correctly + ctx.transform(1,4, 2,3, 5,6); + // Post-transform coordinates: + // [[20,10],[80,10],[80,40],[20,40],[20,10],[40,20],[40,30],[60,30],[60,20],[40,20],[20,10]]; + // Hence pre-transform coordinates: + var pts=[[-7.4,11.2],[-43.4,59.2],[-31.4,53.2],[4.6,5.2],[-7.4,11.2], + [-15.4,25.2],[-11.4,23.2],[-23.4,39.2],[-27.4,41.2],[-15.4,25.2], + [-7.4,11.2]]; + ctx.beginPath(); + ctx.moveTo(pts[0][0], pts[0][1]); + for (var i = 0; i < pts.length; ++i) + ctx.lineTo(pts[i][0], pts[i][1]); + ctx.fill(); + @assert pixel 21,11 == 0,255,0,255; + @assert pixel 79,11 == 0,255,0,255; + @assert pixel 21,39 == 0,255,0,255; + @assert pixel 79,39 == 0,255,0,255; + @assert pixel 39,19 == 0,255,0,255; + @assert pixel 61,19 == 0,255,0,255; + @assert pixel 39,31 == 0,255,0,255; + @assert pixel 61,31 == 0,255,0,255; + expected: green + +- name: 2d.transformation.transform.multiply + desc: transform() multiplies the CTM + testing: + - 2d.transformation.transform.multiply + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.transform(1,2, 3,4, 5,6); + ctx.transform(-2,1, 3/2,-1/2, 1,-2); + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.transformation.transform.nonfinite + desc: transform() with Infinity/NaN is ignored + testing: + - 2d.nonfinite + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.translate(100, 10); + @nonfinite ctx.transform(<0 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(-100, -10, 100, 50); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + + +- name: 2d.transformation.setTransform.skewed + testing: + - 2d.transformation.setTransform + code: | + // Create green with a red square ring inside it + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.fillRect(20, 10, 60, 30); + ctx.fillStyle = '#0f0'; + ctx.fillRect(40, 20, 20, 10); + + // Draw a skewed shape to fill that gap, to make sure it is aligned correctly + ctx.setTransform(1,4, 2,3, 5,6); + // Post-transform coordinates: + // [[20,10],[80,10],[80,40],[20,40],[20,10],[40,20],[40,30],[60,30],[60,20],[40,20],[20,10]]; + // Hence pre-transform coordinates: + var pts=[[-7.4,11.2],[-43.4,59.2],[-31.4,53.2],[4.6,5.2],[-7.4,11.2], + [-15.4,25.2],[-11.4,23.2],[-23.4,39.2],[-27.4,41.2],[-15.4,25.2], + [-7.4,11.2]]; + ctx.beginPath(); + ctx.moveTo(pts[0][0], pts[0][1]); + for (var i = 0; i < pts.length; ++i) + ctx.lineTo(pts[i][0], pts[i][1]); + ctx.fill(); + @assert pixel 21,11 == 0,255,0,255; + @assert pixel 79,11 == 0,255,0,255; + @assert pixel 21,39 == 0,255,0,255; + @assert pixel 79,39 == 0,255,0,255; + @assert pixel 39,19 == 0,255,0,255; + @assert pixel 61,19 == 0,255,0,255; + @assert pixel 39,31 == 0,255,0,255; + @assert pixel 61,31 == 0,255,0,255; + expected: green + +- name: 2d.transformation.setTransform.multiple + testing: + - 2d.transformation.setTransform.identity + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.setTransform(1/2,0, 0,1/2, 0,0); + ctx.setTransform(2,0, 0,2, 0,0); + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 50, 25); + @assert pixel 75,35 == 0,255,0,255; + expected: green + +- name: 2d.transformation.setTransform.nonfinite + desc: setTransform() with Infinity/NaN is ignored + testing: + - 2d.nonfinite + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.translate(100, 10); + @nonfinite ctx.setTransform(<0 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(-100, -10, 100, 50); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + + +- name: 2d.composite.globalAlpha.range + testing: + - 2d.composite.globalAlpha.range + code: | + ctx.globalAlpha = 0.5; + var a = ctx.globalAlpha; // might not be exactly 0.5, if it is rounded/quantised, so remember for future comparisons + ctx.globalAlpha = 1.1; + @assert ctx.globalAlpha === a; + ctx.globalAlpha = -0.1; + @assert ctx.globalAlpha === a; + ctx.globalAlpha = 0; + @assert ctx.globalAlpha === 0; + ctx.globalAlpha = 1; + @assert ctx.globalAlpha === 1; + +- name: 2d.composite.globalAlpha.invalid + testing: + - 2d.composite.globalAlpha.range + code: | + ctx.globalAlpha = 0.5; + var a = ctx.globalAlpha; // might not be exactly 0.5, if it is rounded/quantised, so remember for future comparisons + ctx.globalAlpha = Infinity; + @assert ctx.globalAlpha === a; + ctx.globalAlpha = -Infinity; + @assert ctx.globalAlpha === a; + ctx.globalAlpha = NaN; + @assert ctx.globalAlpha === a; + +- name: 2d.composite.globalAlpha.default + testing: + - 2d.composite.globalAlpha.default + code: | + @assert ctx.globalAlpha === 1.0; + +- name: 2d.composite.globalAlpha.fill + testing: + - 2d.composite.globalAlpha.shape + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.globalAlpha = 0.01; // avoid any potential alpha=0 optimisations + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 ==~ 2,253,0,255; + expected: green + +- name: 2d.composite.globalAlpha.image + testing: + - 2d.composite.globalAlpha.image + images: + - red.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.globalAlpha = 0.01; // avoid any potential alpha=0 optimisations + ctx.drawImage(document.getElementById('red.png'), 0, 0); + @assert pixel 50,25 ==~ 2,253,0,255; + expected: green + +- name: 2d.composite.globalAlpha.canvas + testing: + - 2d.composite.globalAlpha.image + code: | + var canvas2 = document.createElement('canvas'); + canvas2.width = 100; + canvas2.height = 50; + var ctx2 = canvas2.getContext('2d'); + ctx2.fillStyle = '#f00'; + ctx2.fillRect(0, 0, 100, 50); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.globalAlpha = 0.01; // avoid any potential alpha=0 optimisations + ctx.drawImage(canvas2, 0, 0); + @assert pixel 50,25 ==~ 2,253,0,255; + expected: green + +- name: 2d.composite.globalAlpha.imagepattern + testing: + - 2d.composite.globalAlpha.image + images: + - red.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = ctx.createPattern(document.getElementById('red.png'), 'no-repeat'); + ctx.globalAlpha = 0.01; // avoid any potential alpha=0 optimisations + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 ==~ 2,253,0,255; + expected: green + +- name: 2d.composite.globalAlpha.canvaspattern + testing: + - 2d.composite.globalAlpha.image + code: | + var canvas2 = document.createElement('canvas'); + canvas2.width = 100; + canvas2.height = 50; + var ctx2 = canvas2.getContext('2d'); + ctx2.fillStyle = '#f00'; + ctx2.fillRect(0, 0, 100, 50); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = ctx.createPattern(canvas2, 'no-repeat'); + ctx.globalAlpha = 0.01; // avoid any potential alpha=0 optimisations + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 ==~ 2,253,0,255; + expected: green + + +- meta: | + # Composite operation tests + # + ops = [ + # name FA FB + ('source-over', '1', '1-aA'), + ('destination-over', '1-aB', '1'), + ('source-in', 'aB', '0'), + ('destination-in', '0', 'aA'), + ('source-out', '1-aB', '0'), + ('destination-out', '0', '1-aA'), + ('source-atop', 'aB', '1-aA'), + ('destination-atop', '1-aB', 'aA'), + ('xor', '1-aB', '1-aA'), + ('copy', '1', '0'), + ('lighter', '1', '1'), + ] + + # The ones that change the output when src = (0,0,0,0): + ops_trans = [ 'source-in', 'destination-in', 'source-out', 'destination-atop', 'copy' ]; + + def calc_output((RA, GA, BA, aA), (RB, GB, BB, aB), FA_code, FB_code): + rA, gA, bA = RA*aA, GA*aA, BA*aA + rB, gB, bB = RB*aB, GB*aB, BB*aB + + FA = eval(FA_code) + FB = eval(FB_code) + + rO = rA*FA + rB*FB + gO = gA*FA + gB*FB + bO = bA*FA + bB*FB + aO = aA*FA + aB*FB + + rO = min(255, rO) + gO = min(255, gO) + bO = min(255, bO) + aO = min(1, aO) + + if aO: + RO = rO / aO + GO = gO / aO + BO = bO / aO + else: RO = GO = BO = 0 + + return (RO, GO, BO, aO) + + def to_test((r,g,b,a)): + return '%d,%d,%d,%d' % (round(r), round(g), round(b), round(a*255)) + def to_cairo((r,g,b,a)): + return '%f,%f,%f,%f' % (r/255., g/255., b/255., a) + + for (name, src, dest) in [ + ('solid', (255, 255, 0, 1.0), (0, 255, 255, 1.0)), + ('transparent', (0, 0, 255, 0.75), (0, 255, 0, 0.5)), + # catches the atop, xor and lighter bugs in Opera 9.10 + ]: + for op, FA_code, FB_code in ops: + expected = calc_output(src, dest, FA_code, FB_code) + tests.append( { + 'name': '2d.composite.%s.%s' % (name, op), + 'testing': [ '2d.composite.%s' % op ], + 'code': """ + ctx.fillStyle = 'rgba%s'; + ctx.fillRect(0, 0, 100, 50); + ctx.globalCompositeOperation = '%s'; + ctx.fillStyle = 'rgba%s'; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 ==~ %s +/- 5; + """ % (dest, op, src, to_test(expected)), + 'expected': """size 100 50 + cr.set_source_rgba(%s) + cr.rectangle(0, 0, 100, 50) + cr.fill() + """ % to_cairo(expected), + } ) + + for (name, src, dest) in [ ('image', (255, 255, 0, 0.75), (0, 255, 255, 0.5)) ]: + for op, FA_code, FB_code in ops: + expected = calc_output(src, dest, FA_code, FB_code) + tests.append( { + 'name': '2d.composite.%s.%s' % (name, op), + 'testing': [ '2d.composite.%s' % op ], + 'images': [ 'yellow75.png' ], + 'code': """ + ctx.fillStyle = 'rgba%s'; + ctx.fillRect(0, 0, 100, 50); + ctx.globalCompositeOperation = '%s'; + ctx.drawImage(document.getElementById('yellow75.png'), 0, 0); + @assert pixel 50,25 ==~ %s +/- 5; + """ % (dest, op, to_test(expected)), + 'expected': """size 100 50 + cr.set_source_rgba(%s) + cr.rectangle(0, 0, 100, 50) + cr.fill() + """ % to_cairo(expected), + } ) + + for (name, src, dest) in [ ('canvas', (255, 255, 0, 0.75), (0, 255, 255, 0.5)) ]: + for op, FA_code, FB_code in ops: + expected = calc_output(src, dest, FA_code, FB_code) + tests.append( { + 'name': '2d.composite.%s.%s' % (name, op), + 'testing': [ '2d.composite.%s' % op ], + 'images': [ 'yellow75.png' ], + 'code': """ + var canvas2 = document.createElement('canvas'); + canvas2.width = canvas.width; + canvas2.height = canvas.height; + var ctx2 = canvas2.getContext('2d'); + ctx2.drawImage(document.getElementById('yellow75.png'), 0, 0); + ctx.fillStyle = 'rgba%s'; + ctx.fillRect(0, 0, 100, 50); + ctx.globalCompositeOperation = '%s'; + ctx.drawImage(canvas2, 0, 0); + @assert pixel 50,25 ==~ %s +/- 5; + """ % (dest, op, to_test(expected)), + 'expected': """size 100 50 + cr.set_source_rgba(%s) + cr.rectangle(0, 0, 100, 50) + cr.fill() + """ % to_cairo(expected), + } ) + + + for (name, src, dest) in [ ('uncovered.fill', (0, 0, 255, 0.75), (0, 255, 0, 0.5)) ]: + for op, FA_code, FB_code in ops: + if op not in ops_trans: continue + expected0 = calc_output((0,0,0,0.0), dest, FA_code, FB_code) + tests.append( { + 'name': '2d.composite.%s.%s' % (name, op), + 'desc': 'fill() draws pixels not covered by the source object as (0,0,0,0), and does not leave the pixels unchanged.', + 'testing': [ '2d.composite.%s' % op ], + 'code': """ + ctx.fillStyle = 'rgba%s'; + ctx.fillRect(0, 0, 100, 50); + ctx.globalCompositeOperation = '%s'; + ctx.fillStyle = 'rgba%s'; + ctx.translate(0, 25); + ctx.fillRect(0, 50, 100, 50); + @assert pixel 50,25 ==~ %s +/- 5; + """ % (dest, op, src, to_test(expected0)), + 'expected': """size 100 50 + cr.set_source_rgba(%s) + cr.rectangle(0, 0, 100, 50) + cr.fill() + """ % (to_cairo(expected0)), + } ) + + for (name, src, dest) in [ ('uncovered.image', (255, 255, 0, 1.0), (0, 255, 255, 0.5)) ]: + for op, FA_code, FB_code in ops: + if op not in ops_trans: continue + expected0 = calc_output((0,0,0,0.0), dest, FA_code, FB_code) + tests.append( { + 'name': '2d.composite.%s.%s' % (name, op), + 'desc': 'drawImage() draws pixels not covered by the source object as (0,0,0,0), and does not leave the pixels unchanged.', + 'testing': [ '2d.composite.%s' % op ], + 'images': [ 'yellow.png' ], + 'code': """ + ctx.fillStyle = 'rgba%s'; + ctx.fillRect(0, 0, 100, 50); + ctx.globalCompositeOperation = '%s'; + ctx.drawImage(document.getElementById('yellow.png'), 40, 40, 10, 10, 40, 50, 10, 10); + @assert pixel 15,15 ==~ %s +/- 5; + @assert pixel 50,25 ==~ %s +/- 5; + """ % (dest, op, to_test(expected0), to_test(expected0)), + 'expected': """size 100 50 + cr.set_source_rgba(%s) + cr.rectangle(0, 0, 100, 50) + cr.fill() + """ % (to_cairo(expected0)), + } ) + + for (name, src, dest) in [ ('uncovered.nocontext', (255, 255, 0, 1.0), (0, 255, 255, 0.5)) ]: + for op, FA_code, FB_code in ops: + if op not in ops_trans: continue + expected0 = calc_output((0,0,0,0.0), dest, FA_code, FB_code) + tests.append( { + 'name': '2d.composite.%s.%s' % (name, op), + 'desc': 'drawImage() of a canvas with no context draws pixels as (0,0,0,0), and does not leave the pixels unchanged.', + 'testing': [ '2d.composite.%s' % op ], + 'code': """ + ctx.fillStyle = 'rgba%s'; + ctx.fillRect(0, 0, 100, 50); + ctx.globalCompositeOperation = '%s'; + var canvas2 = document.createElement('canvas'); + ctx.drawImage(canvas2, 0, 0); + @assert pixel 50,25 ==~ %s +/- 5; + """ % (dest, op, to_test(expected0)), + 'expected': """size 100 50 + cr.set_source_rgba(%s) + cr.rectangle(0, 0, 100, 50) + cr.fill() + """ % (to_cairo(expected0)), + } ) + + for (name, src, dest) in [ ('uncovered.pattern', (255, 255, 0, 1.0), (0, 255, 255, 0.5)) ]: + for op, FA_code, FB_code in ops: + if op not in ops_trans: continue + expected0 = calc_output((0,0,0,0.0), dest, FA_code, FB_code) + tests.append( { + 'name': '2d.composite.%s.%s' % (name, op), + 'desc': 'Pattern fill() draws pixels not covered by the source object as (0,0,0,0), and does not leave the pixels unchanged.', + 'testing': [ '2d.composite.%s' % op ], + 'images': [ 'yellow.png' ], + 'code': """ + ctx.fillStyle = 'rgba%s'; + ctx.fillRect(0, 0, 100, 50); + ctx.globalCompositeOperation = '%s'; + ctx.fillStyle = ctx.createPattern(document.getElementById('yellow.png'), 'no-repeat'); + ctx.fillRect(0, 50, 100, 50); + @assert pixel 50,25 ==~ %s +/- 5; + """ % (dest, op, to_test(expected0)), + 'expected': """size 100 50 + cr.set_source_rgba(%s) + cr.rectangle(0, 0, 100, 50) + cr.fill() + """ % (to_cairo(expected0)), + } ) + + for op, FA_code, FB_code in ops: + tests.append( { + 'name': '2d.composite.clip.%s' % (op), + 'desc': 'fill() does not affect pixels outside the clip region.', + 'testing': [ '2d.composite.%s' % op ], + 'code': """ + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.globalCompositeOperation = '%s'; + ctx.rect(-20, -20, 10, 10); + ctx.clip(); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 50, 50); + @assert pixel 25,25 == 0,255,0,255; + @assert pixel 75,25 == 0,255,0,255; + """ % (op), + 'expected': 'green' + } ) + +- name: 2d.composite.operation.get + testing: + - 2d.composite.operation + code: | + var modes = ['source-atop', 'source-in', 'source-out', 'source-over', + 'destination-atop', 'destination-in', 'destination-out', 'destination-over', + 'lighter', 'copy', 'xor']; + for (var i = 0; i < modes.length; ++i) + { + ctx.globalCompositeOperation = modes[i]; + @assert ctx.globalCompositeOperation === modes[i]; + } + +- name: 2d.composite.operation.unrecognised + testing: + - 2d.composite.operation.unrecognised + code: | + ctx.globalCompositeOperation = 'xor'; + ctx.globalCompositeOperation = 'nonexistent'; + @assert ctx.globalCompositeOperation === 'xor'; + +- name: 2d.composite.operation.darker + testing: + - 2d.composite.operation.unrecognised + code: | + ctx.globalCompositeOperation = 'xor'; + ctx.globalCompositeOperation = 'darker'; + @assert ctx.globalCompositeOperation === 'xor'; + +- name: 2d.composite.operation.over + testing: + - 2d.composite.operation.unrecognised + code: | + ctx.globalCompositeOperation = 'xor'; + ctx.globalCompositeOperation = 'over'; + @assert ctx.globalCompositeOperation === 'xor'; + +- name: 2d.composite.operation.clear + testing: + - 2d.composite.operation.unrecognised + code: | + ctx.globalCompositeOperation = 'xor'; + ctx.globalCompositeOperation = 'clear'; + @assert ctx.globalCompositeOperation === 'xor'; + +- name: 2d.composite.operation.highlight + testing: + - 2d.composite.operation.unrecognised + code: | + ctx.globalCompositeOperation = 'xor'; + ctx.globalCompositeOperation = 'highlight'; + @assert ctx.globalCompositeOperation === 'xor'; + +- name: 2d.composite.operation.nullsuffix + testing: + - 2d.composite.operation.exact + code: | + ctx.globalCompositeOperation = 'xor'; + ctx.globalCompositeOperation = 'source-over\0'; + @assert ctx.globalCompositeOperation === 'xor'; + +- name: 2d.composite.operation.casesensitive + testing: + - 2d.composite.operation.casesensitive + code: | + ctx.globalCompositeOperation = 'xor'; + ctx.globalCompositeOperation = 'Source-over'; + @assert ctx.globalCompositeOperation === 'xor'; + +- name: 2d.composite.operation.default + testing: + - 2d.composite.operation.default + code: | + @assert ctx.globalCompositeOperation === 'source-over'; + + +- meta: | + # Colour parsing tests + + # Try most of the CSS3 Color values - http://www.w3.org/TR/css3-color/#colorunits + big_float = '1' + ('0' * 39) + big_double = '1' + ('0' * 310) + for name, string, r,g,b,a, notes in [ + ('html4', 'limE', 0,255,0,255, ""), + ('hex3', '#0f0', 0,255,0,255, ""), + ('hex4', '#0f0f', 0,255,0,255, ""), + ('hex6', '#00fF00', 0,255,0,255, ""), + ('hex8', '#00ff00ff', 0,255,0,255, ""), + ('rgb-num', 'rgb(0,255,0)', 0,255,0,255, ""), + ('rgb-clamp-1', 'rgb(-1000, 1000, -1000)', 0,255,0,255, 'Assumes colours are clamped to [0,255].'), + ('rgb-clamp-2', 'rgb(-200%, 200%, -200%)', 0,255,0,255, 'Assumes colours are clamped to [0,255].'), + ('rgb-clamp-3', 'rgb(-2147483649, 4294967298, -18446744073709551619)', 0,255,0,255, 'Assumes colours are clamped to [0,255].'), + ('rgb-clamp-4', 'rgb(-'+big_float+', '+big_float+', -'+big_float+')', 0,255,0,255, 'Assumes colours are clamped to [0,255].'), + ('rgb-clamp-5', 'rgb(-'+big_double+', '+big_double+', -'+big_double+')', 0,255,0,255, 'Assumes colours are clamped to [0,255].'), + ('rgb-percent', 'rgb(0% ,100% ,0%)', 0,255,0,255, 'CSS3 Color says "The integer value 255 corresponds to 100%". (In particular, it is not 254...)'), + ('rgb-eof', 'rgb(0, 255, 0', 0,255,0,255, ""), # see CSS2.1 4.2 "Unexpected end of style sheet" + ('rgba-solid-1', 'rgba( 0 , 255 , 0 , 1 )', 0,255,0,255, ""), + ('rgba-solid-2', 'rgba( 0 , 255 , 0 , 1.0 )', 0,255,0,255, ""), + ('rgba-solid-3', 'rgba( 0 , 255 , 0 , +1 )', 0,255,0,255, ""), + ('rgba-solid-4', 'rgba( -0 , 255 , +0 , 1 )', 0,255,0,255, ""), + ('rgba-num-1', 'rgba( 0 , 255 , 0 , .499 )', 0,255,0,127, ""), + ('rgba-num-2', 'rgba( 0 , 255 , 0 , 0.499 )', 0,255,0,127, ""), + ('rgba-percent', 'rgba(0%,100%,0%,0.499)', 0,255,0,127, ""), # 0.499*255 rounds to 127, both down and nearest, so it should be safe + ('rgba-clamp-1', 'rgba(0, 255, 0, -2)', 0,0,0,0, ""), + ('rgba-clamp-2', 'rgba(0, 255, 0, 2)', 0,255,0,255, ""), + ('rgba-eof', 'rgba(0, 255, 0, 1', 0,255,0,255, ""), + ('transparent-1', 'transparent', 0,0,0,0, ""), + ('transparent-2', 'TrAnSpArEnT', 0,0,0,0, ""), + ('hsl-1', 'hsl(120, 100%, 50%)', 0,255,0,255, ""), + ('hsl-2', 'hsl( -240 , 100% , 50% )', 0,255,0,255, ""), + ('hsl-3', 'hsl(360120, 100%, 50%)', 0,255,0,255, ""), + ('hsl-4', 'hsl(-360240, 100%, 50%)', 0,255,0,255, ""), + ('hsl-5', 'hsl(120.0, 100.0%, 50.0%)', 0,255,0,255, ""), + ('hsl-6', 'hsl(+120, +100%, +50%)', 0,255,0,255, ""), + ('hsl-clamp-1', 'hsl(120, 200%, 50%)', 0,255,0,255, ""), + ('hsl-clamp-2', 'hsl(120, -200%, 49.9%)', 127,127,127,255, ""), + ('hsl-clamp-3', 'hsl(120, 100%, 200%)', 255,255,255,255, ""), + ('hsl-clamp-4', 'hsl(120, 100%, -200%)', 0,0,0,255, ""), + ('hsla-1', 'hsla(120, 100%, 50%, 0.499)', 0,255,0,127, ""), + ('hsla-2', 'hsla( 120.0 , 100.0% , 50.0% , 1 )', 0,255,0,255, ""), + ('hsla-clamp-1', 'hsla(120, 200%, 50%, 1)', 0,255,0,255, ""), + ('hsla-clamp-2', 'hsla(120, -200%, 49.9%, 1)', 127,127,127,255, ""), + ('hsla-clamp-3', 'hsla(120, 100%, 200%, 1)', 255,255,255,255, ""), + ('hsla-clamp-4', 'hsla(120, 100%, -200%, 1)', 0,0,0,255, ""), + ('hsla-clamp-5', 'hsla(120, 100%, 50%, 2)', 0,255,0,255, ""), + ('hsla-clamp-6', 'hsla(120, 100%, 0%, -2)', 0,0,0,0, ""), + ('svg-1', 'gray', 128,128,128,255, ""), + ('svg-2', 'grey', 128,128,128,255, ""), + # css-color-4 rgb() color function + # https://drafts.csswg.org/css-color/#numeric-rgb + ('css-color-4-rgb-1', 'rgb(0, 255.0, 0)', 0,255,0,255, ""), + ('css-color-4-rgb-2', 'rgb(0, 255, 0, 0.2)', 0,255,0,51, ""), + ('css-color-4-rgb-3', 'rgb(0, 255, 0, 20%)', 0,255,0,51, ""), + ('css-color-4-rgb-4', 'rgb(0 255 0)', 0,255,0,255, ""), + ('css-color-4-rgb-5', 'rgb(0 255 0 / 0.2)', 0,255,0,51, ""), + ('css-color-4-rgb-6', 'rgb(0 255 0 / 20%)', 0,255,0,51, ""), + ('css-color-4-rgba-1', 'rgba(0, 255.0, 0)', 0,255,0,255, ""), + ('css-color-4-rgba-2', 'rgba(0, 255, 0, 0.2)', 0,255,0,51, ""), + ('css-color-4-rgba-3', 'rgba(0, 255, 0, 20%)', 0,255,0,51, ""), + ('css-color-4-rgba-4', 'rgba(0 255 0)', 0,255,0,255, ""), + ('css-color-4-rgba-5', 'rgba(0 255 0 / 0.2)', 0,255,0,51, ""), + ('css-color-4-rgba-6', 'rgba(0 255 0 / 20%)', 0,255,0,51, ""), + # css-color-4 hsl() color function + # https://drafts.csswg.org/css-color/#the-hsl-notation + ('css-color-4-hsl-1', 'hsl(120 100.0% 50.0%)', 0,255,0,255, ""), + ('css-color-4-hsl-2', 'hsl(120 100.0% 50.0% / 0.2)', 0,255,0,51, ""), + ('css-color-4-hsl-3', 'hsl(120.0, 100.0%, 50.0%, 0.2)', 0,255,0,51, ""), + ('css-color-4-hsl-4', 'hsl(120.0, 100.0%, 50.0%, 20%)', 0,255,0,51, ""), + ('css-color-4-hsl-5', 'hsl(120deg, 100.0%, 50.0%, 0.2)', 0,255,0,51, ""), + ('css-color-4-hsl-6', 'hsl(120deg, 100.0%, 50.0%)', 0,255,0,255, ""), + ('css-color-4-hsl-7', 'hsl(133.33333333grad, 100.0%, 50.0%)', 0,255,0,255, ""), + ('css-color-4-hsl-8', 'hsl(2.0943951024rad, 100.0%, 50.0%)', 0,255,0,255, ""), + ('css-color-4-hsl-9', 'hsl(0.3333333333turn, 100.0%, 50.0%)', 0,255,0,255, ""), + ('css-color-4-hsla-1', 'hsl(120 100.0% 50.0%)', 0,255,0,255, ""), + ('css-color-4-hsla-2', 'hsl(120 100.0% 50.0% / 0.2)', 0,255,0,51, ""), + ('css-color-4-hsla-3', 'hsl(120.0, 100.0%, 50.0%, 0.2)', 0,255,0,51, ""), + ('css-color-4-hsla-4', 'hsl(120.0, 100.0%, 50.0%, 20%)', 0,255,0,51, ""), + ('css-color-4-hsla-5', 'hsl(120deg, 100.0%, 50.0%, 0.2)', 0,255,0,51, ""), + ('css-color-4-hsla-6', 'hsl(120deg, 100.0%, 50.0%)', 0,255,0,255, ""), + ('css-color-4-hsla-7', 'hsl(133.33333333grad, 100.0%, 50.0%)', 0,255,0,255, ""), + ('css-color-4-hsla-8', 'hsl(2.0943951024rad, 100.0%, 50.0%)', 0,255,0,255, ""), + ('css-color-4-hsla-9', 'hsl(0.3333333333turn, 100.0%, 50.0%)', 0,255,0,255, ""), + # currentColor is handled later + ]: + # TODO: test by retrieving fillStyle, instead of actually drawing? + # TODO: test strokeStyle, shadowColor in the same way + test = { + 'name': '2d.fillStyle.parse.%s' % name, + 'testing': [ '2d.colours.parse' ], + 'notes': notes, + 'code': """ + ctx.fillStyle = '#f00'; + ctx.fillStyle = '%s'; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 == %d,%d,%d,%d; + """ % (string, r,g,b,a), + 'expected': """size 100 50 + cr.set_source_rgba(%f, %f, %f, %f) + cr.rectangle(0, 0, 100, 50) + cr.fill() + """ % (r/255., g/255., b/255., a/255.), + } + tests.append(test) + + # Also test that invalid colours are ignored + for name, string in [ + ('hex1', '#f'), + ('hex2', '#f0'), + ('hex3', '#g00'), + ('hex4', '#fg00'), + ('hex5', '#ff000'), + ('hex6', '#fg0000'), + ('hex7', '#ff0000f'), + ('hex8', '#fg0000ff'), + ('rgb-1', 'rgb(255.0, 0, 0,)'), + ('rgb-2', 'rgb(100%, 0, 0)'), + ('rgb-3', 'rgb(255, - 1, 0)'), + ('rgba-1', 'rgba(100%, 0, 0, 1)'), + ('rgba-2', 'rgba(255, 0, 0, 1. 0)'), + ('rgba-3', 'rgba(255, 0, 0, 1.)'), + ('rgba-4', 'rgba(255, 0, 0, '), + ('rgba-5', 'rgba(255, 0, 0, 1,)'), + ('hsl-1', 'hsl(0%, 100%, 50%)'), + ('hsl-2', 'hsl(z, 100%, 50%)'), + ('hsl-3', 'hsl(0, 0, 50%)'), + ('hsl-4', 'hsl(0, 100%, 0)'), + ('hsl-5', 'hsl(0, 100.%, 50%)'), + ('hsl-6', 'hsl(0, 100%, 50%,)'), + ('hsla-1', 'hsla(0%, 100%, 50%, 1)'), + ('hsla-2', 'hsla(0, 0, 50%, 1)'), + ('hsla-3', 'hsla(0, 0, 50%, 1,)'), + ('name-1', 'darkbrown'), + ('name-2', 'firebrick1'), + ('name-3', 'red blue'), + ('name-4', '"red"'), + ('name-5', '"red'), + # css-color-4 color function + # comma and comma-less expressions should not mix together. + ('css-color-4-rgb-1', 'rgb(255, 0, 0 / 1)'), + ('css-color-4-rgb-2', 'rgb(255 0 0, 1)'), + ('css-color-4-rgb-3', 'rgb(255, 0 0)'), + ('css-color-4-rgba-1', 'rgba(255, 0, 0 / 1)'), + ('css-color-4-rgba-2', 'rgba(255 0 0, 1)'), + ('css-color-4-rgba-3', 'rgba(255, 0 0)'), + ('css-color-4-hsl-1', 'hsl(0, 100%, 50% / 1)'), + ('css-color-4-hsl-2', 'hsl(0 100% 50%, 1)'), + ('css-color-4-hsl-3', 'hsl(0, 100% 50%)'), + ('css-color-4-hsla-1', 'hsla(0, 100%, 50% / 1)'), + ('css-color-4-hsla-2', 'hsla(0 100% 50%, 1)'), + ('css-color-4-hsla-3', 'hsla(0, 100% 50%)'), + # trailing slash + ('css-color-4-rgb-4', 'rgb(0 0 0 /)'), + ('css-color-4-rgb-5', 'rgb(0, 0, 0 /)'), + ('css-color-4-hsl-4', 'hsl(0 100% 50% /)'), + ('css-color-4-hsl-5', 'hsl(0, 100%, 50% /)'), + ]: + test = { + 'name': '2d.fillStyle.parse.invalid.%s' % name, + 'testing': [ '2d.colours.parse' ], + 'code': """ + ctx.fillStyle = '#0f0'; + try { ctx.fillStyle = '%s'; } catch (e) { } // this shouldn't throw, but it shouldn't matter here if it does + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + """ % string, + 'expected': 'green' + } + tests.append(test) + + # Some can't have positive tests, only negative tests, because we don't know what colour they're meant to be + for name, string in [ + ('system', 'ThreeDDarkShadow'), + #('flavor', 'flavor'), # removed from latest CSS3 Color drafts + ]: + test = { + 'name': '2d.fillStyle.parse.%s' % name, + 'testing': [ '2d.colours.parse' ], + 'code': """ + ctx.fillStyle = '#f00'; + ctx.fillStyle = '%s'; + @assert ctx.fillStyle =~ /^#(?!(FF0000|ff0000|f00)$)/; // test that it's not red + """ % (string,), + } + tests.append(test) + +- name: 2d.fillStyle.parse.current.basic + desc: currentColor is computed from the canvas element + testing: + - 2d.colours.parse + - 2d.currentColor.onset + code: | + canvas.setAttribute('style', 'color: #0f0'); + ctx.fillStyle = '#f00'; + ctx.fillStyle = 'currentColor'; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.fillStyle.parse.current.changed + desc: currentColor is computed when the attribute is set, not when it is painted + testing: + - 2d.colours.parse + - 2d.currentColor.onset + code: | + canvas.setAttribute('style', 'color: #0f0'); + ctx.fillStyle = '#f00'; + ctx.fillStyle = 'currentColor'; + canvas.setAttribute('style', 'color: #f00'); + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.fillStyle.parse.current.removed + desc: currentColor is solid black when the canvas element is not in a document + testing: + - 2d.colours.parse + - 2d.currentColor.outofdoc + code: | + // Try not to let it undetectably incorrectly pick up opaque-black + // from other parts of the document: + document.body.parentNode.setAttribute('style', 'color: #f00'); + document.body.setAttribute('style', 'color: #f00'); + canvas.setAttribute('style', 'color: #f00'); + + var canvas2 = document.createElement('canvas'); + var ctx2 = canvas2.getContext('2d'); + ctx2.fillStyle = '#f00'; + ctx2.fillStyle = 'currentColor'; + ctx2.fillRect(0, 0, 100, 50); + ctx.drawImage(canvas2, 0, 0); + + document.body.parentNode.removeAttribute('style'); + document.body.removeAttribute('style'); + + @assert pixel 50,25 == 0,0,0,255; + expected: | + size 100 50 + cr.set_source_rgb(0, 0, 0) + cr.rectangle(0, 0, 100, 50) + cr.fill() + +- name: 2d.fillStyle.invalidstring + testing: + - 2d.colours.invalidstring + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.fillStyle = 'invalid'; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.fillStyle.invalidtype + testing: + - 2d.colours.invalidtype + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.fillStyle = null; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.fillStyle.get.solid + testing: + - 2d.colours.getcolour + - 2d.serializecolour.solid + code: | + ctx.fillStyle = '#fa0'; + @assert ctx.fillStyle === '#ffaa00'; + +- name: 2d.fillStyle.get.semitransparent + testing: + - 2d.colours.getcolour + - 2d.serializecolour.transparent + code: | + ctx.fillStyle = 'rgba(255,255,255,0.45)'; + @assert ctx.fillStyle =~ /^rgba\(255, 255, 255, 0\.4\d+\)$/; + +- name: 2d.fillStyle.get.transparent + testing: + - 2d.colours.getcolour + - 2d.serializecolour.transparent + code: | + ctx.fillStyle = 'rgba(0,0,0,0)'; + @assert ctx.fillStyle === 'rgba(0, 0, 0, 0)'; + +- name: 2d.fillStyle.default + testing: + - 2d.colours.default + code: | + @assert ctx.fillStyle === '#000000'; + +- name: 2d.strokeStyle.default + testing: + - 2d.colours.default + code: | + @assert ctx.strokeStyle === '#000000'; + + +- name: 2d.gradient.object.type + desc: window.CanvasGradient exists and has the right properties + testing: + - 2d.canvasGradient.type + notes: *bindings + code: | + @assert window.CanvasGradient !== undefined; + @assert window.CanvasGradient.prototype.addColorStop !== undefined; + +- name: 2d.gradient.object.return + desc: createLinearGradient() and createRadialGradient() returns objects implementing CanvasGradient + testing: + - 2d.gradient.linear.return + - 2d.gradient.radial.return + code: | + window.CanvasGradient.prototype.thisImplementsCanvasGradient = true; + + var g1 = ctx.createLinearGradient(0, 0, 100, 0); + @assert g1.addColorStop !== undefined; + @assert g1.thisImplementsCanvasGradient === true; + + var g2 = ctx.createRadialGradient(0, 0, 10, 0, 0, 20); + @assert g2.addColorStop !== undefined; + @assert g2.thisImplementsCanvasGradient === true; + +- name: 2d.gradient.interpolate.solid + testing: + - 2d.gradient.interpolate.linear + code: | + var g = ctx.createLinearGradient(0, 0, 100, 0); + g.addColorStop(0, '#0f0'); + g.addColorStop(1, '#0f0'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.gradient.interpolate.colour + testing: + - 2d.gradient.interpolate.linear + code: | + var g = ctx.createLinearGradient(0, 0, 100, 0); + g.addColorStop(0, '#ff0'); + g.addColorStop(1, '#00f'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 25,25 ==~ 191,191,63,255 +/- 3; + @assert pixel 50,25 ==~ 127,127,127,255 +/- 3; + @assert pixel 75,25 ==~ 63,63,191,255 +/- 3; + expected: | + size 100 50 + g = cairo.LinearGradient(0, 0, 100, 0) + g.add_color_stop_rgb(0, 1,1,0) + g.add_color_stop_rgb(1, 0,0,1) + cr.set_source(g) + cr.rectangle(0, 0, 100, 50) + cr.fill() + +- name: 2d.gradient.interpolate.alpha + testing: + - 2d.gradient.interpolate.linear + code: | + ctx.fillStyle = '#ff0'; + ctx.fillRect(0, 0, 100, 50); + var g = ctx.createLinearGradient(0, 0, 100, 0); + g.addColorStop(0, 'rgba(0,0,255, 0)'); + g.addColorStop(1, 'rgba(0,0,255, 1)'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 25,25 ==~ 191,191,63,255 +/- 3; + @assert pixel 50,25 ==~ 127,127,127,255 +/- 3; + @assert pixel 75,25 ==~ 63,63,191,255 +/- 3; + expected: | + size 100 50 + g = cairo.LinearGradient(0, 0, 100, 0) + g.add_color_stop_rgb(0, 1,1,0) + g.add_color_stop_rgb(1, 0,0,1) + cr.set_source(g) + cr.rectangle(0, 0, 100, 50) + cr.fill() + +- name: 2d.gradient.interpolate.colouralpha + testing: + - 2d.gradient.interpolate.alpha + code: | + var g = ctx.createLinearGradient(0, 0, 100, 0); + g.addColorStop(0, 'rgba(255,255,0, 0)'); + g.addColorStop(1, 'rgba(0,0,255, 1)'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 25,25 ==~ 190,190,65,65 +/- 3; + @assert pixel 50,25 ==~ 126,126,128,128 +/- 3; + @assert pixel 75,25 ==~ 62,62,192,192 +/- 3; + expected: | + size 100 50 + g = cairo.LinearGradient(0, 0, 100, 0) + g.add_color_stop_rgba(0, 1,1,0, 0) + g.add_color_stop_rgba(1, 0,0,1, 1) + cr.set_source(g) + cr.rectangle(0, 0, 100, 50) + cr.fill() + +- name: 2d.gradient.interpolate.outside + testing: + - 2d.gradient.outside.first + - 2d.gradient.outside.last + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createLinearGradient(25, 0, 75, 0); + g.addColorStop(0.4, '#0f0'); + g.addColorStop(0.6, '#0f0'); + + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 20,25 ==~ 0,255,0,255; + @assert pixel 50,25 ==~ 0,255,0,255; + @assert pixel 80,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.gradient.interpolate.zerosize.fill + testing: + - 2d.gradient.linear.zerosize + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createLinearGradient(50, 25, 50, 25); // zero-length line (undefined direction) + g.addColorStop(0, '#f00'); + g.addColorStop(1, '#f00'); + ctx.fillStyle = g; + ctx.rect(0, 0, 100, 50); + ctx.fill(); + @assert pixel 40,20 == 0,255,0,255; + expected: green + +- name: 2d.gradient.interpolate.zerosize.stroke + testing: + - 2d.gradient.linear.zerosize + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createLinearGradient(50, 25, 50, 25); // zero-length line (undefined direction) + g.addColorStop(0, '#f00'); + g.addColorStop(1, '#f00'); + ctx.strokeStyle = g; + ctx.rect(20, 20, 60, 10); + ctx.stroke(); + @assert pixel 19,19 == 0,255,0,255; + @assert pixel 20,19 == 0,255,0,255; + @assert pixel 21,19 == 0,255,0,255; + @assert pixel 19,20 == 0,255,0,255; + @assert pixel 20,20 == 0,255,0,255; + @assert pixel 21,20 == 0,255,0,255; + @assert pixel 19,21 == 0,255,0,255; + @assert pixel 20,21 == 0,255,0,255; + @assert pixel 21,21 == 0,255,0,255; + expected: green + +- name: 2d.gradient.interpolate.zerosize.fillRect + testing: + - 2d.gradient.linear.zerosize + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createLinearGradient(50, 25, 50, 25); // zero-length line (undefined direction) + g.addColorStop(0, '#f00'); + g.addColorStop(1, '#f00'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 40,20 == 0,255,0,255; @moz-todo + expected: green + +- name: 2d.gradient.interpolate.zerosize.strokeRect + testing: + - 2d.gradient.linear.zerosize + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createLinearGradient(50, 25, 50, 25); // zero-length line (undefined direction) + g.addColorStop(0, '#f00'); + g.addColorStop(1, '#f00'); + ctx.strokeStyle = g; + ctx.strokeRect(20, 20, 60, 10); + @assert pixel 19,19 == 0,255,0,255; + @assert pixel 20,19 == 0,255,0,255; + @assert pixel 21,19 == 0,255,0,255; + @assert pixel 19,20 == 0,255,0,255; + @assert pixel 20,20 == 0,255,0,255; + @assert pixel 21,20 == 0,255,0,255; + @assert pixel 19,21 == 0,255,0,255; + @assert pixel 20,21 == 0,255,0,255; + @assert pixel 21,21 == 0,255,0,255; + expected: green + +- name: 2d.gradient.interpolate.zerosize.fillText + testing: + - 2d.gradient.linear.zerosize + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createLinearGradient(50, 25, 50, 25); // zero-length line (undefined direction) + g.addColorStop(0, '#f00'); + g.addColorStop(1, '#f00'); + ctx.fillStyle = g; + ctx.font = '100px sans-serif'; + ctx.fillText("AA", 0, 50); + _assertGreen(ctx, 100, 50); + expected: green + +- name: 2d.gradient.interpolate.zerosize.strokeText + testing: + - 2d.gradient.linear.zerosize + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createLinearGradient(50, 25, 50, 25); // zero-length line (undefined direction) + g.addColorStop(0, '#f00'); + g.addColorStop(1, '#f00'); + ctx.strokeStyle = g; + ctx.font = '100px sans-serif'; + ctx.strokeText("AA", 0, 50); + _assertGreen(ctx, 100, 50); + expected: green + + +- name: 2d.gradient.interpolate.vertical + testing: + - 2d.gradient.interpolate.linear + code: | + var g = ctx.createLinearGradient(0, 0, 0, 50); + g.addColorStop(0, '#ff0'); + g.addColorStop(1, '#00f'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,12 ==~ 191,191,63,255 +/- 10; + @assert pixel 50,25 ==~ 127,127,127,255 +/- 5; + @assert pixel 50,37 ==~ 63,63,191,255 +/- 10; + expected: | + size 100 50 + g = cairo.LinearGradient(0, 0, 0, 50) + g.add_color_stop_rgb(0, 1,1,0) + g.add_color_stop_rgb(1, 0,0,1) + cr.set_source(g) + cr.rectangle(0, 0, 100, 50) + cr.fill() + +- name: 2d.gradient.interpolate.multiple + testing: + - 2d.gradient.interpolate.linear + code: | + canvas.width = 200; + var g = ctx.createLinearGradient(0, 0, 200, 0); + g.addColorStop(0, '#ff0'); + g.addColorStop(0.5, '#0ff'); + g.addColorStop(1, '#f0f'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 200, 50); + @assert pixel 50,25 ==~ 127,255,127,255 +/- 3; + @assert pixel 100,25 ==~ 0,255,255,255 +/- 3; + @assert pixel 150,25 ==~ 127,127,255,255 +/- 3; + expected: | + size 200 50 + g = cairo.LinearGradient(0, 0, 200, 0) + g.add_color_stop_rgb(0.0, 1,1,0) + g.add_color_stop_rgb(0.5, 0,1,1) + g.add_color_stop_rgb(1.0, 1,0,1) + cr.set_source(g) + cr.rectangle(0, 0, 200, 50) + cr.fill() + +- name: 2d.gradient.interpolate.overlap + testing: + - 2d.gradient.interpolate.overlap + code: | + canvas.width = 200; + var g = ctx.createLinearGradient(0, 0, 200, 0); + g.addColorStop(0, '#f00'); + g.addColorStop(0, '#ff0'); + g.addColorStop(0.25, '#00f'); + g.addColorStop(0.25, '#0f0'); + g.addColorStop(0.25, '#0f0'); + g.addColorStop(0.25, '#0f0'); + g.addColorStop(0.25, '#ff0'); + g.addColorStop(0.5, '#00f'); + g.addColorStop(0.5, '#0f0'); + g.addColorStop(0.75, '#00f'); + g.addColorStop(0.75, '#f00'); + g.addColorStop(0.75, '#ff0'); + g.addColorStop(0.5, '#0f0'); + g.addColorStop(0.5, '#0f0'); + g.addColorStop(0.5, '#ff0'); + g.addColorStop(1, '#00f'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 200, 50); + @assert pixel 49,25 ==~ 0,0,255,255 +/- 16; + @assert pixel 51,25 ==~ 255,255,0,255 +/- 16; + @assert pixel 99,25 ==~ 0,0,255,255 +/- 16; + @assert pixel 101,25 ==~ 255,255,0,255 +/- 16; + @assert pixel 149,25 ==~ 0,0,255,255 +/- 16; + @assert pixel 151,25 ==~ 255,255,0,255 +/- 16; + expected: | + size 200 50 + g = cairo.LinearGradient(0, 0, 50, 0) + g.add_color_stop_rgb(0, 1,1,0) + g.add_color_stop_rgb(1, 0,0,1) + cr.set_source(g) + cr.rectangle(0, 0, 50, 50) + cr.fill() + + g = cairo.LinearGradient(50, 0, 100, 0) + g.add_color_stop_rgb(0, 1,1,0) + g.add_color_stop_rgb(1, 0,0,1) + cr.set_source(g) + cr.rectangle(50, 0, 50, 50) + cr.fill() + + g = cairo.LinearGradient(100, 0, 150, 0) + g.add_color_stop_rgb(0, 1,1,0) + g.add_color_stop_rgb(1, 0,0,1) + cr.set_source(g) + cr.rectangle(100, 0, 50, 50) + cr.fill() + + g = cairo.LinearGradient(150, 0, 200, 0) + g.add_color_stop_rgb(0, 1,1,0) + g.add_color_stop_rgb(1, 0,0,1) + cr.set_source(g) + cr.rectangle(150, 0, 50, 50) + cr.fill() + +- name: 2d.gradient.interpolate.overlap2 + testing: + - 2d.gradient.interpolate.overlap + code: | + var g = ctx.createLinearGradient(0, 0, 100, 0); + var ps = [ 0, 1/10, 1/4, 1/3, 1/2, 3/4, 1 ]; + for (var p = 0; p < ps.length; ++p) + { + g.addColorStop(ps[p], '#0f0'); + for (var i = 0; i < 15; ++i) + g.addColorStop(ps[p], '#f00'); + g.addColorStop(ps[p], '#0f0'); + } + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 1,25 == 0,255,0,255; + @assert pixel 30,25 == 0,255,0,255; + @assert pixel 40,25 == 0,255,0,255; + @assert pixel 60,25 == 0,255,0,255; + @assert pixel 80,25 == 0,255,0,255; + expected: green + +- name: 2d.gradient.empty + testing: + - 2d.gradient.empty + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + var g = ctx.createLinearGradient(0, 0, 0, 50); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.gradient.object.update + testing: + - 2d.gradient.update + code: | + var g = ctx.createLinearGradient(-100, 0, 200, 0); + g.addColorStop(0, '#f00'); + g.addColorStop(1, '#f00'); + ctx.fillStyle = g; + g.addColorStop(0.1, '#0f0'); + g.addColorStop(0.9, '#0f0'); + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.gradient.object.compare + testing: + - 2d.gradient.object + code: | + var g1 = ctx.createLinearGradient(0, 0, 100, 0); + var g2 = ctx.createLinearGradient(0, 0, 100, 0); + @assert g1 !== g2; + ctx.fillStyle = g1; + @assert ctx.fillStyle === g1; + +- name: 2d.gradient.object.crosscanvas + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + var g = document.createElement('canvas').getContext('2d').createLinearGradient(0, 0, 100, 0); + g.addColorStop(0, '#0f0'); + g.addColorStop(1, '#0f0'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.gradient.object.current + testing: + - 2d.currentColor.gradient + code: | + canvas.setAttribute('style', 'color: #f00'); + + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createLinearGradient(0, 0, 100, 0); + g.addColorStop(0, 'currentColor'); + g.addColorStop(1, 'currentColor'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 ==~ 0,0,0,255; + expected: | + size 100 50 + cr.set_source_rgb(0, 0, 0) + cr.rectangle(0, 0, 100, 50) + cr.fill() + +- name: 2d.gradient.object.invalidoffset + testing: + - 2d.gradient.invalidoffset + code: | + var g = ctx.createLinearGradient(0, 0, 100, 0); + @assert throws INDEX_SIZE_ERR g.addColorStop(-1, '#000'); + @assert throws INDEX_SIZE_ERR g.addColorStop(2, '#000'); + @assert throws TypeError g.addColorStop(Infinity, '#000'); + @assert throws TypeError g.addColorStop(-Infinity, '#000'); + @assert throws TypeError g.addColorStop(NaN, '#000'); + +- name: 2d.gradient.object.invalidcolour + testing: + - 2d.gradient.invalidcolour + code: | + var g = ctx.createLinearGradient(0, 0, 100, 0); + @assert throws SYNTAX_ERR g.addColorStop(0, ""); + @assert throws SYNTAX_ERR g.addColorStop(0, 'null'); + @assert throws SYNTAX_ERR g.addColorStop(0, 'undefined'); + @assert throws SYNTAX_ERR g.addColorStop(0, null); + @assert throws SYNTAX_ERR g.addColorStop(0, undefined); + + +- name: 2d.gradient.linear.nonfinite + desc: createLinearGradient() throws TypeError if arguments are not finite + notes: *bindings + testing: + - 2d.gradient.linear.nonfinite + code: | + @nonfinite @assert throws TypeError ctx.createLinearGradient(<0 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <1 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>); + +- name: 2d.gradient.linear.transform.1 + desc: Linear gradient coordinates are relative to the coordinate space at the time of filling + testing: + - 2d.gradient.linear.transform + code: | + var g = ctx.createLinearGradient(0, 0, 200, 0); + g.addColorStop(0, '#f00'); + g.addColorStop(0.25, '#0f0'); + g.addColorStop(0.75, '#0f0'); + g.addColorStop(1, '#f00'); + ctx.fillStyle = g; + ctx.translate(-50, 0); + ctx.fillRect(50, 0, 100, 50); + @assert pixel 25,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 75,25 == 0,255,0,255; + expected: green + +- name: 2d.gradient.linear.transform.2 + desc: Linear gradient coordinates are relative to the coordinate space at the time of filling + testing: + - 2d.gradient.linear.transform + code: | + ctx.translate(100, 0); + var g = ctx.createLinearGradient(0, 0, 200, 0); + g.addColorStop(0, '#f00'); + g.addColorStop(0.25, '#0f0'); + g.addColorStop(0.75, '#0f0'); + g.addColorStop(1, '#f00'); + ctx.fillStyle = g; + ctx.translate(-150, 0); + ctx.fillRect(50, 0, 100, 50); + @assert pixel 25,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 75,25 == 0,255,0,255; + expected: green + +- name: 2d.gradient.linear.transform.3 + desc: Linear gradient transforms do not experience broken caching effects + testing: + - 2d.gradient.linear.transform + code: | + var g = ctx.createLinearGradient(0, 0, 200, 0); + g.addColorStop(0, '#f00'); + g.addColorStop(0.25, '#0f0'); + g.addColorStop(0.75, '#0f0'); + g.addColorStop(1, '#f00'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + ctx.translate(-50, 0); + ctx.fillRect(50, 0, 100, 50); + @assert pixel 25,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 75,25 == 0,255,0,255; + expected: green + +- name: 2d.gradient.radial.negative + desc: createRadialGradient() throws INDEX_SIZE_ERR if either radius is negative + testing: + - 2d.gradient.radial.negative + code: | + @assert throws INDEX_SIZE_ERR ctx.createRadialGradient(0, 0, -0.1, 0, 0, 1); + @assert throws INDEX_SIZE_ERR ctx.createRadialGradient(0, 0, 1, 0, 0, -0.1); + @assert throws INDEX_SIZE_ERR ctx.createRadialGradient(0, 0, -0.1, 0, 0, -0.1); + +- name: 2d.gradient.radial.nonfinite + desc: createRadialGradient() throws TypeError if arguments are not finite + notes: *bindings + testing: + - 2d.gradient.radial.nonfinite + code: | + @nonfinite @assert throws TypeError ctx.createRadialGradient(<0 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <1 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <1 Infinity -Infinity NaN>); + +- name: 2d.gradient.radial.inside1 + testing: + - 2d.gradient.radial.rendering + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createRadialGradient(50, 25, 100, 50, 25, 200); + g.addColorStop(0, '#0f0'); + g.addColorStop(1, '#f00'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 50,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,25 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 50,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.gradient.radial.inside2 + testing: + - 2d.gradient.radial.rendering + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createRadialGradient(50, 25, 200, 50, 25, 100); + g.addColorStop(0, '#f00'); + g.addColorStop(1, '#0f0'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 50,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,25 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 50,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.gradient.radial.inside3 + testing: + - 2d.gradient.radial.rendering + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createRadialGradient(50, 25, 200, 50, 25, 100); + g.addColorStop(0, '#f00'); + g.addColorStop(0.993, '#f00'); + g.addColorStop(1, '#0f0'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 50,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,25 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 50,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.gradient.radial.outside1 + testing: + - 2d.gradient.radial.rendering + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createRadialGradient(200, 25, 10, 200, 25, 20); + g.addColorStop(0, '#f00'); + g.addColorStop(1, '#0f0'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 50,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,25 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 50,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.gradient.radial.outside2 + testing: + - 2d.gradient.radial.rendering + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createRadialGradient(200, 25, 20, 200, 25, 10); + g.addColorStop(0, '#0f0'); + g.addColorStop(1, '#f00'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 50,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,25 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 50,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.gradient.radial.outside3 + testing: + - 2d.gradient.radial.rendering + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createRadialGradient(200, 25, 20, 200, 25, 10); + g.addColorStop(0, '#0f0'); + g.addColorStop(0.001, '#f00'); + g.addColorStop(1, '#f00'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 50,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,25 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 50,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.gradient.radial.touch1 + testing: + - 2d.gradient.radial.rendering + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createRadialGradient(150, 25, 50, 200, 25, 100); + g.addColorStop(0, '#f00'); + g.addColorStop(1, '#f00'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; @moz-todo + @assert pixel 50,1 == 0,255,0,255; @moz-todo + @assert pixel 98,1 == 0,255,0,255; @moz-todo + @assert pixel 1,25 == 0,255,0,255; @moz-todo + @assert pixel 50,25 == 0,255,0,255; @moz-todo + @assert pixel 98,25 == 0,255,0,255; @moz-todo + @assert pixel 1,48 == 0,255,0,255; @moz-todo + @assert pixel 50,48 == 0,255,0,255; @moz-todo + @assert pixel 98,48 == 0,255,0,255; @moz-todo + expected: green + +- name: 2d.gradient.radial.touch2 + testing: + - 2d.gradient.radial.rendering + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createRadialGradient(-80, 25, 70, 0, 25, 150); + g.addColorStop(0, '#f00'); + g.addColorStop(0.01, '#0f0'); + g.addColorStop(0.99, '#0f0'); + g.addColorStop(1, '#f00'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 50,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,25 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 50,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.gradient.radial.touch3 + testing: + - 2d.gradient.radial.rendering + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createRadialGradient(120, -15, 25, 140, -30, 50); + g.addColorStop(0, '#f00'); + g.addColorStop(1, '#f00'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; @moz-todo + @assert pixel 50,1 == 0,255,0,255; @moz-todo + @assert pixel 98,1 == 0,255,0,255; @moz-todo + @assert pixel 1,25 == 0,255,0,255; @moz-todo + @assert pixel 50,25 == 0,255,0,255; @moz-todo + @assert pixel 98,25 == 0,255,0,255; @moz-todo + @assert pixel 1,48 == 0,255,0,255; @moz-todo + @assert pixel 50,48 == 0,255,0,255; @moz-todo + @assert pixel 98,48 == 0,255,0,255; @moz-todo + expected: green + +- name: 2d.gradient.radial.equal + testing: + - 2d.gradient.radial.equal + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createRadialGradient(50, 25, 20, 50, 25, 20); + g.addColorStop(0, '#f00'); + g.addColorStop(1, '#f00'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; @moz-todo + @assert pixel 50,1 == 0,255,0,255; @moz-todo + @assert pixel 98,1 == 0,255,0,255; @moz-todo + @assert pixel 1,25 == 0,255,0,255; @moz-todo + @assert pixel 50,25 == 0,255,0,255; @moz-todo + @assert pixel 98,25 == 0,255,0,255; @moz-todo + @assert pixel 1,48 == 0,255,0,255; @moz-todo + @assert pixel 50,48 == 0,255,0,255; @moz-todo + @assert pixel 98,48 == 0,255,0,255; @moz-todo + expected: green + +- name: 2d.gradient.radial.cone.behind + testing: + - 2d.gradient.radial.rendering + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createRadialGradient(120, 25, 10, 211, 25, 100); + g.addColorStop(0, '#f00'); + g.addColorStop(1, '#f00'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; @moz-todo + @assert pixel 50,1 == 0,255,0,255; @moz-todo + @assert pixel 98,1 == 0,255,0,255; @moz-todo + @assert pixel 1,25 == 0,255,0,255; @moz-todo + @assert pixel 50,25 == 0,255,0,255; @moz-todo + @assert pixel 98,25 == 0,255,0,255; @moz-todo + @assert pixel 1,48 == 0,255,0,255; @moz-todo + @assert pixel 50,48 == 0,255,0,255; @moz-todo + @assert pixel 98,48 == 0,255,0,255; @moz-todo + expected: green + +- name: 2d.gradient.radial.cone.front + testing: + - 2d.gradient.radial.rendering + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createRadialGradient(311, 25, 10, 210, 25, 100); + g.addColorStop(0, '#f00'); + g.addColorStop(1, '#0f0'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 50,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,25 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 50,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.gradient.radial.cone.bottom + testing: + - 2d.gradient.radial.rendering + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createRadialGradient(210, 25, 100, 230, 25, 101); + g.addColorStop(0, '#0f0'); + g.addColorStop(1, '#f00'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 50,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,25 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 50,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.gradient.radial.cone.top + testing: + - 2d.gradient.radial.rendering + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createRadialGradient(230, 25, 100, 100, 25, 101); + g.addColorStop(0, '#f00'); + g.addColorStop(1, '#0f0'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 50,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,25 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 50,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.gradient.radial.cone.beside + testing: + - 2d.gradient.radial.rendering + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createRadialGradient(0, 100, 40, 100, 100, 50); + g.addColorStop(0, '#f00'); + g.addColorStop(1, '#f00'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; @moz-todo + @assert pixel 50,1 == 0,255,0,255; @moz-todo + @assert pixel 98,1 == 0,255,0,255; @moz-todo + @assert pixel 1,25 == 0,255,0,255; @moz-todo + @assert pixel 50,25 == 0,255,0,255; @moz-todo + @assert pixel 98,25 == 0,255,0,255; @moz-todo + @assert pixel 1,48 == 0,255,0,255; @moz-todo + @assert pixel 50,48 == 0,255,0,255; @moz-todo + @assert pixel 98,48 == 0,255,0,255; @moz-todo + expected: green + +- name: 2d.gradient.radial.cone.cylinder + testing: + - 2d.gradient.radial.rendering + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createRadialGradient(210, 25, 100, 230, 25, 100); + g.addColorStop(0, '#0f0'); + g.addColorStop(1, '#f00'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 50,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,25 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 50,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.gradient.radial.cone.shape1 + testing: + - 2d.gradient.radial.rendering + code: | + var tol = 1; // tolerance to avoid antialiasing artifacts + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.fillStyle = '#f00'; + ctx.beginPath(); + ctx.moveTo(30+tol, 40); + ctx.lineTo(110, -20+tol); + ctx.lineTo(110, 100-tol); + ctx.fill(); + + var g = ctx.createRadialGradient(30+10*5/2, 40, 10*3/2, 30+10*15/4, 40, 10*9/4); + g.addColorStop(0, '#0f0'); + g.addColorStop(1, '#0f0'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 50,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,25 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 50,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.gradient.radial.cone.shape2 + testing: + - 2d.gradient.radial.rendering + code: | + var tol = 1; // tolerance to avoid antialiasing artifacts + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + var g = ctx.createRadialGradient(30+10*5/2, 40, 10*3/2, 30+10*15/4, 40, 10*9/4); + g.addColorStop(0, '#f00'); + g.addColorStop(1, '#f00'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + + ctx.fillStyle = '#0f0'; + ctx.beginPath(); + ctx.moveTo(30-tol, 40); + ctx.lineTo(110, -20-tol); + ctx.lineTo(110, 100+tol); + ctx.fill(); + + @assert pixel 1,1 == 0,255,0,255; @moz-todo + @assert pixel 50,1 == 0,255,0,255; @moz-todo + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,25 == 0,255,0,255; @moz-todo + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,25 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; @moz-todo + @assert pixel 50,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.gradient.radial.transform.1 + desc: Radial gradient coordinates are relative to the coordinate space at the time of filling + testing: + - 2d.gradient.radial.transform + code: | + var g = ctx.createRadialGradient(0, 0, 0, 0, 0, 11.2); + g.addColorStop(0, '#0f0'); + g.addColorStop(0.5, '#0f0'); + g.addColorStop(0.51, '#f00'); + g.addColorStop(1, '#f00'); + ctx.fillStyle = g; + ctx.translate(50, 25); + ctx.scale(10, 10); + ctx.fillRect(-5, -2.5, 10, 5); + @assert pixel 25,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 75,25 == 0,255,0,255; + expected: green + +- name: 2d.gradient.radial.transform.2 + desc: Radial gradient coordinates are relative to the coordinate space at the time of filling + testing: + - 2d.gradient.radial.transform + code: | + ctx.translate(100, 0); + var g = ctx.createRadialGradient(0, 0, 0, 0, 0, 11.2); + g.addColorStop(0, '#0f0'); + g.addColorStop(0.5, '#0f0'); + g.addColorStop(0.51, '#f00'); + g.addColorStop(1, '#f00'); + ctx.fillStyle = g; + ctx.translate(-50, 25); + ctx.scale(10, 10); + ctx.fillRect(-5, -2.5, 10, 5); + @assert pixel 25,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 75,25 == 0,255,0,255; + expected: green + +- name: 2d.gradient.radial.transform.3 + desc: Radial gradient transforms do not experience broken caching effects + testing: + - 2d.gradient.radial.transform + code: | + var g = ctx.createRadialGradient(0, 0, 0, 0, 0, 11.2); + g.addColorStop(0, '#0f0'); + g.addColorStop(0.5, '#0f0'); + g.addColorStop(0.51, '#f00'); + g.addColorStop(1, '#f00'); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 100, 50); + ctx.translate(50, 25); + ctx.scale(10, 10); + ctx.fillRect(-5, -2.5, 10, 5); + @assert pixel 25,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 75,25 == 0,255,0,255; + expected: green + + + + + + +- name: 2d.pattern.basic.type + testing: + - 2d.pattern.return + images: + - green.png + code: | + @assert window.CanvasPattern !== undefined; + + window.CanvasPattern.prototype.thisImplementsCanvasPattern = true; + + var img = document.getElementById('green.png'); + var pattern = ctx.createPattern(img, 'no-repeat'); + @assert pattern.thisImplementsCanvasPattern; + +- name: 2d.pattern.basic.image + testing: + - 2d.pattern.painting + images: + - green.png + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + var img = document.getElementById('green.png'); + var pattern = ctx.createPattern(img, 'no-repeat'); + ctx.fillStyle = pattern; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.basic.canvas + testing: + - 2d.pattern.painting + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + var canvas2 = document.createElement('canvas'); + canvas2.width = 100; + canvas2.height = 50; + var ctx2 = canvas2.getContext('2d'); + ctx2.fillStyle = '#0f0'; + ctx2.fillRect(0, 0, 100, 50); + + var pattern = ctx.createPattern(canvas2, 'no-repeat'); + ctx.fillStyle = pattern; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 50,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,25 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 50,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.basic.zerocanvas + testing: + - 2d.pattern.zerocanvas + code: | + canvas.width = 0; + canvas.height = 10; + @assert canvas.width === 0; + @assert canvas.height === 10; + @assert throws INVALID_STATE_ERR ctx.createPattern(canvas, 'repeat'); + + canvas.width = 10; + canvas.height = 0; + @assert canvas.width === 10; + @assert canvas.height === 0; + @assert throws INVALID_STATE_ERR ctx.createPattern(canvas, 'repeat'); + + canvas.width = 0; + canvas.height = 0; + @assert canvas.width === 0; + @assert canvas.height === 0; + @assert throws INVALID_STATE_ERR ctx.createPattern(canvas, 'repeat'); + +- name: 2d.pattern.basic.nocontext + testing: + - 2d.pattern.painting + code: | + var canvas2 = document.createElement('canvas'); + canvas2.width = 100; + canvas2.height = 50; + var pattern = ctx.createPattern(canvas2, 'no-repeat'); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.fillStyle = pattern; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.image.undefined + testing: + - 2d.pattern.IDL + notes: *bindings + code: | + @assert throws TypeError ctx.createPattern(undefined, 'repeat'); + +- name: 2d.pattern.image.null + testing: + - 2d.pattern.IDL + notes: *bindings + code: | + @assert throws TypeError ctx.createPattern(null, 'repeat'); + +- name: 2d.pattern.image.string + testing: + - 2d.pattern.IDL + notes: *bindings + code: | + @assert throws TypeError ctx.createPattern('../images/red.png', 'repeat'); + +- name: 2d.pattern.image.incomplete.nosrc + testing: + - 2d.pattern.incomplete.image + mozilla: { throws } + code: | + var img = new Image(); + @assert ctx.createPattern(img, 'repeat') === null; + +- name: 2d.pattern.image.incomplete.immediate + testing: + - 2d.pattern.incomplete.image + images: + - red.png + code: | + var img = new Image(); + img.src = '../images/red.png'; + // This triggers the "update the image data" algorithm. + // The image will not go to the "completely available" state + // until a fetch task in the networking task source is processed, + // so the image must not be fully decodable yet: + @assert ctx.createPattern(img, 'repeat') === null; @moz-todo + +- name: 2d.pattern.image.incomplete.reload + testing: + - 2d.pattern.incomplete.image + images: + - yellow.png + - red.png + code: | + var img = document.getElementById('yellow.png'); + img.src = '../images/red.png'; + // This triggers the "update the image data" algorithm, + // and resets the image to the "unavailable" state. + // The image will not go to the "completely available" state + // until a fetch task in the networking task source is processed, + // so the image must not be fully decodable yet: + @assert ctx.createPattern(img, 'repeat') === null; @moz-todo + +- name: 2d.pattern.image.incomplete.emptysrc + testing: + - 2d.pattern.incomplete.image + images: + - red.png + mozilla: { throws } + code: | + var img = document.getElementById('red.png'); + img.src = ""; + @assert ctx.createPattern(img, 'repeat') === null; + +- name: 2d.pattern.image.incomplete.removedsrc + testing: + - 2d.pattern.incomplete.image + images: + - red.png + mozilla: { throws } + code: | + var img = document.getElementById('red.png'); + img.removeAttribute('src'); + @assert ctx.createPattern(img, 'repeat') === null; + +- name: 2d.pattern.image.broken + testing: + - 2d.pattern.incomplete.image + images: + - broken.png + code: | + var img = document.getElementById('broken.png'); + @assert throws INVALID_STATE_ERR ctx.createPattern(img, 'repeat'); + +- name: 2d.pattern.repeat.empty + testing: + - 2d.pattern.missing + images: + - green-1x1.png + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + var img = document.getElementById('green-1x1.png'); + var pattern = ctx.createPattern(img, ""); + ctx.fillStyle = pattern; + ctx.fillRect(0, 0, 200, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.repeat.null + testing: + - 2d.pattern.unrecognised + code: | + @assert ctx.createPattern(canvas, null) != null; + +- name: 2d.pattern.repeat.undefined + testing: + - 2d.pattern.unrecognised + code: | + @assert throws SYNTAX_ERR ctx.createPattern(canvas, undefined); + +- name: 2d.pattern.repeat.unrecognised + testing: + - 2d.pattern.unrecognised + code: | + @assert throws SYNTAX_ERR ctx.createPattern(canvas, "invalid"); + +- name: 2d.pattern.repeat.unrecognisednull + testing: + - 2d.pattern.unrecognised + code: | + @assert throws SYNTAX_ERR ctx.createPattern(canvas, "null"); + +- name: 2d.pattern.repeat.case + testing: + - 2d.pattern.exact + code: | + @assert throws SYNTAX_ERR ctx.createPattern(canvas, "Repeat"); + +- name: 2d.pattern.repeat.nullsuffix + testing: + - 2d.pattern.exact + code: | + @assert throws SYNTAX_ERR ctx.createPattern(canvas, "repeat\0"); + +- name: 2d.pattern.modify.image1 + testing: + - 2d.pattern.modify + images: + - green.png + code: | + var img = document.getElementById('green.png'); + var pattern = ctx.createPattern(img, 'no-repeat'); + deferTest(); + img.onload = t.step_func_done(function () + { + ctx.fillStyle = pattern; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + }); + img.src = '/images/red.png'; + expected: green + +- name: 2d.pattern.modify.image2 + testing: + - 2d.pattern.modify + images: + - green.png + code: | + var img = document.getElementById('green.png'); + var pattern = ctx.createPattern(img, 'no-repeat'); + ctx.fillStyle = pattern; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#00f'; + ctx.fillRect(0, 0, 100, 50); + deferTest(); + img.onload = t.step_func_done(function () + { + ctx.fillStyle = pattern; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + }); + img.src = '/images/red.png'; + expected: green + +- name: 2d.pattern.modify.canvas1 + testing: + - 2d.pattern.modify + code: | + var canvas2 = document.createElement('canvas'); + canvas2.width = 100; + canvas2.height = 50; + var ctx2 = canvas2.getContext('2d'); + ctx2.fillStyle = '#0f0'; + ctx2.fillRect(0, 0, 100, 50); + + var pattern = ctx.createPattern(canvas2, 'no-repeat'); + + ctx2.fillStyle = '#f00'; + ctx2.fillRect(0, 0, 100, 50); + + ctx.fillStyle = pattern; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.modify.canvas2 + testing: + - 2d.pattern.modify + code: | + var canvas2 = document.createElement('canvas'); + canvas2.width = 100; + canvas2.height = 50; + var ctx2 = canvas2.getContext('2d'); + ctx2.fillStyle = '#0f0'; + ctx2.fillRect(0, 0, 100, 50); + + var pattern = ctx.createPattern(canvas2, 'no-repeat'); + ctx.fillStyle = pattern; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx2.fillStyle = '#f00'; + ctx2.fillRect(0, 0, 100, 50); + + ctx.fillStyle = pattern; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.crosscanvas + images: + - green.png + code: | + var img = document.getElementById('green.png'); + + var pattern = document.createElement('canvas').getContext('2d').createPattern(img, 'no-repeat'); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = pattern; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.pattern.paint.norepeat.basic + testing: + - 2d.pattern.painting + images: + - green.png + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + var img = document.getElementById('green.png'); + var pattern = ctx.createPattern(img, 'no-repeat'); + ctx.fillStyle = pattern; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.paint.norepeat.outside + testing: + - 2d.pattern.painting + images: + - red.png + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + var img = document.getElementById('red.png'); + var pattern = ctx.createPattern(img, 'no-repeat'); + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.fillStyle = pattern; + ctx.fillRect(0, -50, 100, 50); + ctx.fillRect(-100, 0, 100, 50); + ctx.fillRect(0, 50, 100, 50); + ctx.fillRect(100, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.paint.norepeat.coord1 + testing: + - 2d.pattern.painting + images: + - green.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 50, 50); + ctx.fillStyle = '#f00'; + ctx.fillRect(50, 0, 50, 50); + + var img = document.getElementById('green.png'); + var pattern = ctx.createPattern(img, 'no-repeat'); + ctx.fillStyle = pattern; + ctx.translate(50, 0); + ctx.fillRect(-50, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.paint.norepeat.coord2 + testing: + - 2d.pattern.painting + images: + - green.png + code: | + var img = document.getElementById('green.png'); + var pattern = ctx.createPattern(img, 'no-repeat'); + ctx.fillStyle = pattern; + ctx.fillRect(0, 0, 50, 50); + + ctx.fillStyle = '#f00'; + ctx.fillRect(50, 0, 50, 50); + + ctx.fillStyle = pattern; + ctx.translate(50, 0); + ctx.fillRect(-50, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.paint.norepeat.coord3 + testing: + - 2d.pattern.painting + images: + - red.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + var img = document.getElementById('red.png'); + var pattern = ctx.createPattern(img, 'no-repeat'); + ctx.fillStyle = pattern; + ctx.translate(50, 25); + ctx.fillRect(-50, -25, 100, 50); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 50, 25); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.paint.repeat.basic + testing: + - 2d.pattern.painting + images: + - green-16x16.png + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + var img = document.getElementById('green-16x16.png'); + var pattern = ctx.createPattern(img, 'repeat'); + ctx.fillStyle = pattern; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.paint.repeat.outside + testing: + - 2d.pattern.painting + images: + - green-16x16.png + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + var img = document.getElementById('green-16x16.png'); + var pattern = ctx.createPattern(img, 'repeat'); + ctx.fillStyle = pattern; + ctx.translate(50, 25); + ctx.fillRect(-50, -25, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.paint.repeat.coord1 + testing: + - 2d.pattern.painting + images: + - rgrg-256x256.png + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + var img = document.getElementById('rgrg-256x256.png'); + var pattern = ctx.createPattern(img, 'repeat'); + ctx.fillStyle = pattern; + ctx.translate(-128, -78); + ctx.fillRect(128, 78, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.paint.repeat.coord2 + testing: + - 2d.pattern.painting + images: + - ggrr-256x256.png + code: | + var img = document.getElementById('ggrr-256x256.png'); + var pattern = ctx.createPattern(img, 'repeat'); + ctx.fillStyle = pattern; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.paint.repeat.coord3 + testing: + - 2d.pattern.painting + images: + - rgrg-256x256.png + code: | + var img = document.getElementById('rgrg-256x256.png'); + var pattern = ctx.createPattern(img, 'repeat'); + ctx.fillStyle = pattern; + ctx.fillRect(0, 0, 100, 50); + + ctx.translate(-128, -78); + ctx.fillRect(128, 78, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.paint.repeatx.basic + testing: + - 2d.pattern.painting + images: + - green-16x16.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 16); + + var img = document.getElementById('green-16x16.png'); + var pattern = ctx.createPattern(img, 'repeat-x'); + ctx.fillStyle = pattern; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.paint.repeatx.outside + testing: + - 2d.pattern.painting + images: + - red-16x16.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + var img = document.getElementById('red-16x16.png'); + var pattern = ctx.createPattern(img, 'repeat-x'); + ctx.fillStyle = pattern; + ctx.fillRect(0, 0, 100, 50); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 16); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.paint.repeatx.coord1 + testing: + - 2d.pattern.painting + images: + - red-16x16.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + var img = document.getElementById('red-16x16.png'); + var pattern = ctx.createPattern(img, 'repeat-x'); + ctx.fillStyle = pattern; + ctx.translate(0, 16); + ctx.fillRect(0, -16, 100, 50); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 16); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,25 == 0,255,0,255; + @assert pixel 98,25 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.paint.repeaty.basic + testing: + - 2d.pattern.painting + images: + - green-16x16.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 16, 50); + + var img = document.getElementById('green-16x16.png'); + var pattern = ctx.createPattern(img, 'repeat-y'); + ctx.fillStyle = pattern; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.paint.repeaty.outside + testing: + - 2d.pattern.painting + images: + - red-16x16.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + var img = document.getElementById('red-16x16.png'); + var pattern = ctx.createPattern(img, 'repeat-y'); + ctx.fillStyle = pattern; + ctx.fillRect(0, 0, 100, 50); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 16, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.paint.repeaty.coord1 + testing: + - 2d.pattern.painting + images: + - red-16x16.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + var img = document.getElementById('red-16x16.png'); + var pattern = ctx.createPattern(img, 'repeat-y'); + ctx.fillStyle = pattern; + ctx.translate(48, 0); + ctx.fillRect(-48, 0, 100, 50); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 16, 50); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 50,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 50,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.paint.orientation.image + desc: Image patterns do not get flipped when painted + testing: + - 2d.pattern.painting + images: + - rrgg-256x256.png + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + var img = document.getElementById('rrgg-256x256.png'); + var pattern = ctx.createPattern(img, 'no-repeat'); + ctx.fillStyle = pattern; + ctx.save(); + ctx.translate(0, -103); + ctx.fillRect(0, 103, 100, 50); + ctx.restore(); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 25); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.pattern.paint.orientation.canvas + desc: Canvas patterns do not get flipped when painted + testing: + - 2d.pattern.painting + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + var canvas2 = document.createElement('canvas'); + canvas2.width = 100; + canvas2.height = 50; + var ctx2 = canvas2.getContext('2d'); + ctx2.fillStyle = '#f00'; + ctx2.fillRect(0, 0, 100, 25); + ctx2.fillStyle = '#0f0'; + ctx2.fillRect(0, 25, 100, 25); + + var pattern = ctx.createPattern(canvas2, 'no-repeat'); + ctx.fillStyle = pattern; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 25); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + + +- name: 2d.pattern.animated.gif + desc: createPattern() of an animated GIF draws the first frame + testing: + - 2d.pattern.animated.image + images: + - anim-gr.gif + code: | + deferTest(); + setTimeout(function () { + var pattern = ctx.createPattern(document.getElementById('anim-gr.gif'), 'repeat'); + ctx.fillStyle = pattern; + ctx.fillRect(0, 0, 50, 50); + setTimeout(t.step_func_done(function () { + ctx.fillRect(50, 0, 50, 50); + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + }), 250); + }, 250); + expected: green + + + + +- name: 2d.line.defaults + testing: + - 2d.lineWidth.default + - 2d.lineCap.default + - 2d.lineJoin.default + - 2d.miterLimit.default + code: | + @assert ctx.lineWidth === 1; + @assert ctx.lineCap === 'butt'; + @assert ctx.lineJoin === 'miter'; + @assert ctx.miterLimit === 10; + +- name: 2d.line.width.basic + desc: lineWidth determines the width of line strokes + testing: + - 2d.lineWidth + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.lineWidth = 20; + // Draw a green line over a red box, to check the line is not too small + ctx.fillStyle = '#f00'; + ctx.strokeStyle = '#0f0'; + ctx.fillRect(15, 15, 20, 20); + ctx.beginPath(); + ctx.moveTo(25, 15); + ctx.lineTo(25, 35); + ctx.stroke(); + + // Draw a green box over a red line, to check the line is not too large + ctx.fillStyle = '#0f0'; + ctx.strokeStyle = '#f00'; + ctx.beginPath(); + ctx.moveTo(75, 15); + ctx.lineTo(75, 35); + ctx.stroke(); + ctx.fillRect(65, 15, 20, 20); + + @assert pixel 14,25 == 0,255,0,255; + @assert pixel 15,25 == 0,255,0,255; + @assert pixel 16,25 == 0,255,0,255; + @assert pixel 25,25 == 0,255,0,255; + @assert pixel 34,25 == 0,255,0,255; + @assert pixel 35,25 == 0,255,0,255; + @assert pixel 36,25 == 0,255,0,255; + + @assert pixel 64,25 == 0,255,0,255; + @assert pixel 65,25 == 0,255,0,255; + @assert pixel 66,25 == 0,255,0,255; + @assert pixel 75,25 == 0,255,0,255; + @assert pixel 84,25 == 0,255,0,255; + @assert pixel 85,25 == 0,255,0,255; + @assert pixel 86,25 == 0,255,0,255; + expected: green + +- name: 2d.line.width.transformed + desc: Line stroke widths are affected by scale transformations + testing: + - 2d.lineWidth + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.lineWidth = 4; + // Draw a green line over a red box, to check the line is not too small + ctx.fillStyle = '#f00'; + ctx.strokeStyle = '#0f0'; + ctx.fillRect(15, 15, 20, 20); + ctx.save(); + ctx.scale(5, 1); + ctx.beginPath(); + ctx.moveTo(5, 15); + ctx.lineTo(5, 35); + ctx.stroke(); + ctx.restore(); + + // Draw a green box over a red line, to check the line is not too large + ctx.fillStyle = '#0f0'; + ctx.strokeStyle = '#f00'; + ctx.save(); + ctx.scale(-5, 1); + ctx.beginPath(); + ctx.moveTo(-15, 15); + ctx.lineTo(-15, 35); + ctx.stroke(); + ctx.restore(); + ctx.fillRect(65, 15, 20, 20); + + @assert pixel 14,25 == 0,255,0,255; + @assert pixel 15,25 == 0,255,0,255; + @assert pixel 16,25 == 0,255,0,255; + @assert pixel 25,25 == 0,255,0,255; + @assert pixel 34,25 == 0,255,0,255; + @assert pixel 35,25 == 0,255,0,255; + @assert pixel 36,25 == 0,255,0,255; + + @assert pixel 64,25 == 0,255,0,255; + @assert pixel 65,25 == 0,255,0,255; + @assert pixel 66,25 == 0,255,0,255; + @assert pixel 75,25 == 0,255,0,255; + @assert pixel 84,25 == 0,255,0,255; + @assert pixel 85,25 == 0,255,0,255; + @assert pixel 86,25 == 0,255,0,255; + expected: green + +- name: 2d.line.width.scaledefault + desc: Default lineWidth strokes are affected by scale transformations + testing: + - 2d.lineWidth + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.scale(50, 50); + ctx.strokeStyle = '#0f0'; + ctx.moveTo(0, 0.5); + ctx.lineTo(2, 0.5); + ctx.stroke(); + + @assert pixel 25,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 75,25 == 0,255,0,255; + @assert pixel 50,5 == 0,255,0,255; + @assert pixel 50,45 == 0,255,0,255; + expected: green + +- name: 2d.line.width.valid + desc: Setting lineWidth to valid values works + testing: + - 2d.lineWidth.set + - 2d.lineWidth.get + code: | + ctx.lineWidth = 1.5; + @assert ctx.lineWidth === 1.5; + + ctx.lineWidth = "1e1"; + @assert ctx.lineWidth === 10; + + ctx.lineWidth = 1/1024; + @assert ctx.lineWidth === 1/1024; + + ctx.lineWidth = 1000; + @assert ctx.lineWidth === 1000; + +- name: 2d.line.width.invalid + desc: Setting lineWidth to invalid values is ignored + testing: + - 2d.lineWidth.invalid + code: | + ctx.lineWidth = 1.5; + @assert ctx.lineWidth === 1.5; + + ctx.lineWidth = 1.5; + ctx.lineWidth = 0; + @assert ctx.lineWidth === 1.5; + + ctx.lineWidth = 1.5; + ctx.lineWidth = -1; + @assert ctx.lineWidth === 1.5; + + ctx.lineWidth = 1.5; + ctx.lineWidth = Infinity; + @assert ctx.lineWidth === 1.5; + + ctx.lineWidth = 1.5; + ctx.lineWidth = -Infinity; + @assert ctx.lineWidth === 1.5; + + ctx.lineWidth = 1.5; + ctx.lineWidth = NaN; + @assert ctx.lineWidth === 1.5; + +- name: 2d.line.cap.butt + desc: lineCap 'butt' is rendered correctly + testing: + - 2d.lineCap.butt + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.lineCap = 'butt'; + ctx.lineWidth = 20; + + ctx.fillStyle = '#f00'; + ctx.strokeStyle = '#0f0'; + ctx.fillRect(15, 15, 20, 20); + ctx.beginPath(); + ctx.moveTo(25, 15); + ctx.lineTo(25, 35); + ctx.stroke(); + + ctx.fillStyle = '#0f0'; + ctx.strokeStyle = '#f00'; + ctx.beginPath(); + ctx.moveTo(75, 15); + ctx.lineTo(75, 35); + ctx.stroke(); + ctx.fillRect(65, 15, 20, 20); + + @assert pixel 25,14 == 0,255,0,255; + @assert pixel 25,15 == 0,255,0,255; + @assert pixel 25,16 == 0,255,0,255; + @assert pixel 25,34 == 0,255,0,255; + @assert pixel 25,35 == 0,255,0,255; + @assert pixel 25,36 == 0,255,0,255; + + @assert pixel 75,14 == 0,255,0,255; + @assert pixel 75,15 == 0,255,0,255; + @assert pixel 75,16 == 0,255,0,255; + @assert pixel 75,34 == 0,255,0,255; + @assert pixel 75,35 == 0,255,0,255; + @assert pixel 75,36 == 0,255,0,255; + expected: green + +- name: 2d.line.cap.round + desc: lineCap 'round' is rendered correctly + testing: + - 2d.lineCap.round + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + var tol = 1; // tolerance to avoid antialiasing artifacts + + ctx.lineCap = 'round'; + ctx.lineWidth = 20; + + + ctx.fillStyle = '#f00'; + ctx.strokeStyle = '#0f0'; + + ctx.beginPath(); + ctx.moveTo(35-tol, 15); + ctx.arc(25, 15, 10-tol, 0, Math.PI, true); + ctx.arc(25, 35, 10-tol, Math.PI, 0, true); + ctx.fill(); + + ctx.beginPath(); + ctx.moveTo(25, 15); + ctx.lineTo(25, 35); + ctx.stroke(); + + + ctx.fillStyle = '#0f0'; + ctx.strokeStyle = '#f00'; + + ctx.beginPath(); + ctx.moveTo(75, 15); + ctx.lineTo(75, 35); + ctx.stroke(); + + ctx.beginPath(); + ctx.moveTo(85+tol, 15); + ctx.arc(75, 15, 10+tol, 0, Math.PI, true); + ctx.arc(75, 35, 10+tol, Math.PI, 0, true); + ctx.fill(); + + @assert pixel 17,6 == 0,255,0,255; + @assert pixel 25,6 == 0,255,0,255; + @assert pixel 32,6 == 0,255,0,255; + @assert pixel 17,43 == 0,255,0,255; + @assert pixel 25,43 == 0,255,0,255; + @assert pixel 32,43 == 0,255,0,255; + + @assert pixel 67,6 == 0,255,0,255; + @assert pixel 75,6 == 0,255,0,255; + @assert pixel 82,6 == 0,255,0,255; + @assert pixel 67,43 == 0,255,0,255; + @assert pixel 75,43 == 0,255,0,255; + @assert pixel 82,43 == 0,255,0,255; + expected: green + +- name: 2d.line.cap.square + desc: lineCap 'square' is rendered correctly + testing: + - 2d.lineCap.square + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.lineCap = 'square'; + ctx.lineWidth = 20; + + ctx.fillStyle = '#f00'; + ctx.strokeStyle = '#0f0'; + ctx.fillRect(15, 5, 20, 40); + ctx.beginPath(); + ctx.moveTo(25, 15); + ctx.lineTo(25, 35); + ctx.stroke(); + + ctx.fillStyle = '#0f0'; + ctx.strokeStyle = '#f00'; + ctx.beginPath(); + ctx.moveTo(75, 15); + ctx.lineTo(75, 35); + ctx.stroke(); + ctx.fillRect(65, 5, 20, 40); + + @assert pixel 25,4 == 0,255,0,255; + @assert pixel 25,5 == 0,255,0,255; + @assert pixel 25,6 == 0,255,0,255; + @assert pixel 25,44 == 0,255,0,255; + @assert pixel 25,45 == 0,255,0,255; + @assert pixel 25,46 == 0,255,0,255; + + @assert pixel 75,4 == 0,255,0,255; + @assert pixel 75,5 == 0,255,0,255; + @assert pixel 75,6 == 0,255,0,255; + @assert pixel 75,44 == 0,255,0,255; + @assert pixel 75,45 == 0,255,0,255; + @assert pixel 75,46 == 0,255,0,255; + expected: green + +- name: 2d.line.cap.open + desc: Line caps are drawn at the corners of an unclosed rectangle + testing: + - 2d.lineCap.end + code: | + ctx.fillStyle = '#f00'; + ctx.strokeStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.lineJoin = 'bevel'; + ctx.lineCap = 'square'; + ctx.lineWidth = 400; + + ctx.beginPath(); + ctx.moveTo(200, 200); + ctx.lineTo(200, 1000); + ctx.lineTo(1000, 1000); + ctx.lineTo(1000, 200); + ctx.lineTo(200, 200); + ctx.stroke(); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 48,1 == 0,255,0,255; + @assert pixel 48,48 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + expected: green + +- name: 2d.line.cap.closed + desc: Line caps are not drawn at the corners of an unclosed rectangle + testing: + - 2d.lineCap.end + code: | + ctx.fillStyle = '#0f0'; + ctx.strokeStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.lineJoin = 'bevel'; + ctx.lineCap = 'square'; + ctx.lineWidth = 400; + + ctx.beginPath(); + ctx.moveTo(200, 200); + ctx.lineTo(200, 1000); + ctx.lineTo(1000, 1000); + ctx.lineTo(1000, 200); + ctx.closePath(); + ctx.stroke(); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 48,1 == 0,255,0,255; + @assert pixel 48,48 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + expected: green + +- name: 2d.line.cap.valid + desc: Setting lineCap to valid values works + testing: + - 2d.lineCap.set + - 2d.lineCap.get + code: | + ctx.lineCap = 'butt' + @assert ctx.lineCap === 'butt'; + + ctx.lineCap = 'round'; + @assert ctx.lineCap === 'round'; + + ctx.lineCap = 'square'; + @assert ctx.lineCap === 'square'; + +- name: 2d.line.cap.invalid + desc: Setting lineCap to invalid values is ignored + testing: + - 2d.lineCap.invalid + code: | + ctx.lineCap = 'butt' + @assert ctx.lineCap === 'butt'; + + ctx.lineCap = 'butt'; + ctx.lineCap = 'invalid'; + @assert ctx.lineCap === 'butt'; + + ctx.lineCap = 'butt'; + ctx.lineCap = 'ROUND'; + @assert ctx.lineCap === 'butt'; + + ctx.lineCap = 'butt'; + ctx.lineCap = 'round\0'; + @assert ctx.lineCap === 'butt'; + + ctx.lineCap = 'butt'; + ctx.lineCap = 'round '; + @assert ctx.lineCap === 'butt'; + + ctx.lineCap = 'butt'; + ctx.lineCap = ""; + @assert ctx.lineCap === 'butt'; + + ctx.lineCap = 'butt'; + ctx.lineCap = 'bevel'; + @assert ctx.lineCap === 'butt'; + +- name: 2d.line.join.bevel + desc: lineJoin 'bevel' is rendered correctly + testing: + - 2d.lineJoin.common + - 2d.lineJoin.bevel + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + var tol = 1; // tolerance to avoid antialiasing artifacts + + ctx.lineJoin = 'bevel'; + ctx.lineWidth = 20; + + ctx.fillStyle = '#f00'; + ctx.strokeStyle = '#0f0'; + + ctx.fillRect(10, 10, 20, 20); + ctx.fillRect(20, 20, 20, 20); + ctx.beginPath(); + ctx.moveTo(30, 20); + ctx.lineTo(40-tol, 20); + ctx.lineTo(30, 10+tol); + ctx.fill(); + + ctx.beginPath(); + ctx.moveTo(10, 20); + ctx.lineTo(30, 20); + ctx.lineTo(30, 40); + ctx.stroke(); + + + ctx.fillStyle = '#0f0'; + ctx.strokeStyle = '#f00'; + + ctx.beginPath(); + ctx.moveTo(60, 20); + ctx.lineTo(80, 20); + ctx.lineTo(80, 40); + ctx.stroke(); + + ctx.fillRect(60, 10, 20, 20); + ctx.fillRect(70, 20, 20, 20); + ctx.beginPath(); + ctx.moveTo(80, 20); + ctx.lineTo(90+tol, 20); + ctx.lineTo(80, 10-tol); + ctx.fill(); + + @assert pixel 34,16 == 0,255,0,255; + @assert pixel 34,15 == 0,255,0,255; + @assert pixel 35,15 == 0,255,0,255; + @assert pixel 36,15 == 0,255,0,255; + @assert pixel 36,14 == 0,255,0,255; + + @assert pixel 84,16 == 0,255,0,255; + @assert pixel 84,15 == 0,255,0,255; + @assert pixel 85,15 == 0,255,0,255; + @assert pixel 86,15 == 0,255,0,255; + @assert pixel 86,14 == 0,255,0,255; + expected: green + +- name: 2d.line.join.round + desc: lineJoin 'round' is rendered correctly + testing: + - 2d.lineJoin.round + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + var tol = 1; // tolerance to avoid antialiasing artifacts + + ctx.lineJoin = 'round'; + ctx.lineWidth = 20; + + ctx.fillStyle = '#f00'; + ctx.strokeStyle = '#0f0'; + + ctx.fillRect(10, 10, 20, 20); + ctx.fillRect(20, 20, 20, 20); + ctx.beginPath(); + ctx.moveTo(30, 20); + ctx.arc(30, 20, 10-tol, 0, 2*Math.PI, true); + ctx.fill(); + + ctx.beginPath(); + ctx.moveTo(10, 20); + ctx.lineTo(30, 20); + ctx.lineTo(30, 40); + ctx.stroke(); + + + ctx.fillStyle = '#0f0'; + ctx.strokeStyle = '#f00'; + + ctx.beginPath(); + ctx.moveTo(60, 20); + ctx.lineTo(80, 20); + ctx.lineTo(80, 40); + ctx.stroke(); + + ctx.fillRect(60, 10, 20, 20); + ctx.fillRect(70, 20, 20, 20); + ctx.beginPath(); + ctx.moveTo(80, 20); + ctx.arc(80, 20, 10+tol, 0, 2*Math.PI, true); + ctx.fill(); + + @assert pixel 36,14 == 0,255,0,255; + @assert pixel 36,13 == 0,255,0,255; + @assert pixel 37,13 == 0,255,0,255; + @assert pixel 38,13 == 0,255,0,255; + @assert pixel 38,12 == 0,255,0,255; + + @assert pixel 86,14 == 0,255,0,255; + @assert pixel 86,13 == 0,255,0,255; + @assert pixel 87,13 == 0,255,0,255; + @assert pixel 88,13 == 0,255,0,255; + @assert pixel 88,12 == 0,255,0,255; + expected: green + +- name: 2d.line.join.miter + desc: lineJoin 'miter' is rendered correctly + testing: + - 2d.lineJoin.miter + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.lineJoin = 'miter'; + ctx.lineWidth = 20; + + ctx.fillStyle = '#f00'; + ctx.strokeStyle = '#0f0'; + + ctx.fillStyle = '#f00'; + ctx.strokeStyle = '#0f0'; + + ctx.fillRect(10, 10, 30, 20); + ctx.fillRect(20, 10, 20, 30); + + ctx.beginPath(); + ctx.moveTo(10, 20); + ctx.lineTo(30, 20); + ctx.lineTo(30, 40); + ctx.stroke(); + + + ctx.fillStyle = '#0f0'; + ctx.strokeStyle = '#f00'; + + ctx.beginPath(); + ctx.moveTo(60, 20); + ctx.lineTo(80, 20); + ctx.lineTo(80, 40); + ctx.stroke(); + + ctx.fillRect(60, 10, 30, 20); + ctx.fillRect(70, 10, 20, 30); + + @assert pixel 38,12 == 0,255,0,255; + @assert pixel 39,11 == 0,255,0,255; + @assert pixel 40,10 == 0,255,0,255; + @assert pixel 41,9 == 0,255,0,255; + @assert pixel 42,8 == 0,255,0,255; + + @assert pixel 88,12 == 0,255,0,255; + @assert pixel 89,11 == 0,255,0,255; + @assert pixel 90,10 == 0,255,0,255; + @assert pixel 91,9 == 0,255,0,255; + @assert pixel 92,8 == 0,255,0,255; + expected: green + +- name: 2d.line.join.open + desc: Line joins are not drawn at the corner of an unclosed rectangle + testing: + - 2d.lineJoin.joins + code: | + ctx.fillStyle = '#0f0'; + ctx.strokeStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.lineJoin = 'miter'; + ctx.lineWidth = 200; + + ctx.beginPath(); + ctx.moveTo(100, 50); + ctx.lineTo(100, 1000); + ctx.lineTo(1000, 1000); + ctx.lineTo(1000, 50); + ctx.lineTo(100, 50); + ctx.stroke(); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 48,1 == 0,255,0,255; + @assert pixel 48,48 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + expected: green + +- name: 2d.line.join.closed + desc: Line joins are drawn at the corner of a closed rectangle + testing: + - 2d.lineJoin.joinclosed + code: | + ctx.fillStyle = '#f00'; + ctx.strokeStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.lineJoin = 'miter'; + ctx.lineWidth = 200; + + ctx.beginPath(); + ctx.moveTo(100, 50); + ctx.lineTo(100, 1000); + ctx.lineTo(1000, 1000); + ctx.lineTo(1000, 50); + ctx.closePath(); + ctx.stroke(); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 48,1 == 0,255,0,255; + @assert pixel 48,48 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + expected: green + +- name: 2d.line.join.parallel + desc: Line joins are drawn at 180-degree joins + testing: + - 2d.lineJoin.joins + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 300; + ctx.lineJoin = 'round'; + ctx.beginPath(); + ctx.moveTo(-100, 25); + ctx.lineTo(0, 25); + ctx.lineTo(-100, 25); + ctx.stroke(); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 48,1 == 0,255,0,255; + @assert pixel 48,48 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + expected: green + +- name: 2d.line.join.valid + desc: Setting lineJoin to valid values works + testing: + - 2d.lineJoin.set + - 2d.lineJoin.get + code: | + ctx.lineJoin = 'bevel' + @assert ctx.lineJoin === 'bevel'; + + ctx.lineJoin = 'round'; + @assert ctx.lineJoin === 'round'; + + ctx.lineJoin = 'miter'; + @assert ctx.lineJoin === 'miter'; + +- name: 2d.line.join.invalid + desc: Setting lineJoin to invalid values is ignored + testing: + - 2d.lineJoin.invalid + code: | + ctx.lineJoin = 'bevel' + @assert ctx.lineJoin === 'bevel'; + + ctx.lineJoin = 'bevel'; + ctx.lineJoin = 'invalid'; + @assert ctx.lineJoin === 'bevel'; + + ctx.lineJoin = 'bevel'; + ctx.lineJoin = 'ROUND'; + @assert ctx.lineJoin === 'bevel'; + + ctx.lineJoin = 'bevel'; + ctx.lineJoin = 'round\0'; + @assert ctx.lineJoin === 'bevel'; + + ctx.lineJoin = 'bevel'; + ctx.lineJoin = 'round '; + @assert ctx.lineJoin === 'bevel'; + + ctx.lineJoin = 'bevel'; + ctx.lineJoin = ""; + @assert ctx.lineJoin === 'bevel'; + + ctx.lineJoin = 'bevel'; + ctx.lineJoin = 'butt'; + @assert ctx.lineJoin === 'bevel'; + +- name: 2d.line.miter.exceeded + desc: Miter joins are not drawn when the miter limit is exceeded + testing: + - 2d.lineJoin.miterLimit + - 2d.lineJoin.miter + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.lineWidth = 400; + ctx.lineJoin = 'miter'; + + ctx.strokeStyle = '#f00'; + ctx.miterLimit = 1.414; + ctx.beginPath(); + ctx.moveTo(200, 1000); + ctx.lineTo(200, 200); + ctx.lineTo(1000, 201); // slightly non-right-angle to avoid being a special case + ctx.stroke(); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 48,1 == 0,255,0,255; + @assert pixel 48,48 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + expected: green + +- name: 2d.line.miter.acute + desc: Miter joins are drawn correctly with acute angles + testing: + - 2d.lineJoin.miterLimit + - 2d.lineJoin.miter + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.lineWidth = 200; + ctx.lineJoin = 'miter'; + + ctx.strokeStyle = '#0f0'; + ctx.miterLimit = 2.614; + ctx.beginPath(); + ctx.moveTo(100, 1000); + ctx.lineTo(100, 100); + ctx.lineTo(1000, 1000); + ctx.stroke(); + + ctx.strokeStyle = '#f00'; + ctx.miterLimit = 2.613; + ctx.beginPath(); + ctx.moveTo(100, 1000); + ctx.lineTo(100, 100); + ctx.lineTo(1000, 1000); + ctx.stroke(); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 48,1 == 0,255,0,255; + @assert pixel 48,48 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + expected: green + +- name: 2d.line.miter.obtuse + desc: Miter joins are drawn correctly with obtuse angles + testing: + - 2d.lineJoin.miterLimit + - 2d.lineJoin.miter + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.lineWidth = 1600; + ctx.lineJoin = 'miter'; + + ctx.strokeStyle = '#0f0'; + ctx.miterLimit = 1.083; + ctx.beginPath(); + ctx.moveTo(800, 10000); + ctx.lineTo(800, 300); + ctx.lineTo(10000, -8900); + ctx.stroke(); + + ctx.strokeStyle = '#f00'; + ctx.miterLimit = 1.082; + ctx.beginPath(); + ctx.moveTo(800, 10000); + ctx.lineTo(800, 300); + ctx.lineTo(10000, -8900); + ctx.stroke(); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 48,1 == 0,255,0,255; + @assert pixel 48,48 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + expected: green + +- name: 2d.line.miter.rightangle + desc: Miter joins are not drawn when the miter limit is exceeded, on exact right angles + testing: + - 2d.lineJoin.miter + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.lineWidth = 400; + ctx.lineJoin = 'miter'; + + ctx.strokeStyle = '#f00'; + ctx.miterLimit = 1.414; + ctx.beginPath(); + ctx.moveTo(200, 1000); + ctx.lineTo(200, 200); + ctx.lineTo(1000, 200); + ctx.stroke(); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 48,1 == 0,255,0,255; + @assert pixel 48,48 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + expected: green + +- name: 2d.line.miter.lineedge + desc: Miter joins are not drawn when the miter limit is exceeded at the corners of a zero-height rectangle + testing: + - 2d.lineJoin.miter + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.lineWidth = 200; + ctx.lineJoin = 'miter'; + + ctx.strokeStyle = '#f00'; + ctx.miterLimit = 1.414; + ctx.beginPath(); + ctx.strokeRect(100, 25, 200, 0); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 48,1 == 0,255,0,255; + @assert pixel 48,48 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + expected: green + +- name: 2d.line.miter.within + desc: Miter joins are drawn when the miter limit is not quite exceeded + testing: + - 2d.lineJoin.miter + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.lineWidth = 400; + ctx.lineJoin = 'miter'; + + ctx.strokeStyle = '#0f0'; + ctx.miterLimit = 1.416; + ctx.beginPath(); + ctx.moveTo(200, 1000); + ctx.lineTo(200, 200); + ctx.lineTo(1000, 201); + ctx.stroke(); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 48,1 == 0,255,0,255; + @assert pixel 48,48 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + expected: green + +- name: 2d.line.miter.valid + desc: Setting miterLimit to valid values works + testing: + - 2d.miterLimit.set + - 2d.miterLimit.get + code: | + ctx.miterLimit = 1.5; + @assert ctx.miterLimit === 1.5; + + ctx.miterLimit = "1e1"; + @assert ctx.miterLimit === 10; + + ctx.miterLimit = 1/1024; + @assert ctx.miterLimit === 1/1024; + + ctx.miterLimit = 1000; + @assert ctx.miterLimit === 1000; + +- name: 2d.line.miter.invalid + desc: Setting miterLimit to invalid values is ignored + testing: + - 2d.miterLimit.invalid + code: | + ctx.miterLimit = 1.5; + @assert ctx.miterLimit === 1.5; + + ctx.miterLimit = 1.5; + ctx.miterLimit = 0; + @assert ctx.miterLimit === 1.5; + + ctx.miterLimit = 1.5; + ctx.miterLimit = -1; + @assert ctx.miterLimit === 1.5; + + ctx.miterLimit = 1.5; + ctx.miterLimit = Infinity; + @assert ctx.miterLimit === 1.5; + + ctx.miterLimit = 1.5; + ctx.miterLimit = -Infinity; + @assert ctx.miterLimit === 1.5; + + ctx.miterLimit = 1.5; + ctx.miterLimit = NaN; + @assert ctx.miterLimit === 1.5; + +- name: 2d.line.cross + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.lineWidth = 200; + ctx.lineJoin = 'bevel'; + + ctx.strokeStyle = '#f00'; + ctx.beginPath(); + ctx.moveTo(110, 50); + ctx.lineTo(110, 60); + ctx.lineTo(100, 60); + ctx.stroke(); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 48,1 == 0,255,0,255; + @assert pixel 48,48 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + expected: green + +- name: 2d.line.union + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.lineWidth = 100; + ctx.lineCap = 'round'; + + ctx.strokeStyle = '#0f0'; + ctx.beginPath(); + ctx.moveTo(0, 24); + ctx.lineTo(100, 25); + ctx.lineTo(0, 26); + ctx.closePath(); + ctx.stroke(); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 25,1 == 0,255,0,255; + @assert pixel 48,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 25,1 == 0,255,0,255; + @assert pixel 48,48 == 0,255,0,255; + expected: green + + + + + + + +- name: 2d.shadow.attributes.shadowBlur.initial + testing: + - 2d.shadow.blur.get + - 2d.shadow.blur.initial + code: | + @assert ctx.shadowBlur === 0; + +- name: 2d.shadow.attributes.shadowBlur.valid + testing: + - 2d.shadow.blur.get + - 2d.shadow.blur.set + code: | + ctx.shadowBlur = 1; + @assert ctx.shadowBlur === 1; + + ctx.shadowBlur = 0.5; + @assert ctx.shadowBlur === 0.5; + + ctx.shadowBlur = 1e6; + @assert ctx.shadowBlur === 1e6; + + ctx.shadowBlur = 0; + @assert ctx.shadowBlur === 0; + +- name: 2d.shadow.attributes.shadowBlur.invalid + testing: + - 2d.shadow.blur.invalid + code: | + ctx.shadowBlur = 1; + ctx.shadowBlur = -2; + @assert ctx.shadowBlur === 1; + + ctx.shadowBlur = 1; + ctx.shadowBlur = Infinity; + @assert ctx.shadowBlur === 1; + + ctx.shadowBlur = 1; + ctx.shadowBlur = -Infinity; + @assert ctx.shadowBlur === 1; + + ctx.shadowBlur = 1; + ctx.shadowBlur = NaN; + @assert ctx.shadowBlur === 1; + +- name: 2d.shadow.attributes.shadowOffset.initial + testing: + - 2d.shadow.offset.initial + code: | + @assert ctx.shadowOffsetX === 0; + @assert ctx.shadowOffsetY === 0; + +- name: 2d.shadow.attributes.shadowOffset.valid + testing: + - 2d.shadow.offset.get + - 2d.shadow.offset.set + code: | + ctx.shadowOffsetX = 1; + ctx.shadowOffsetY = 2; + @assert ctx.shadowOffsetX === 1; + @assert ctx.shadowOffsetY === 2; + + ctx.shadowOffsetX = 0.5; + ctx.shadowOffsetY = 0.25; + @assert ctx.shadowOffsetX === 0.5; + @assert ctx.shadowOffsetY === 0.25; + + ctx.shadowOffsetX = -0.5; + ctx.shadowOffsetY = -0.25; + @assert ctx.shadowOffsetX === -0.5; + @assert ctx.shadowOffsetY === -0.25; + + ctx.shadowOffsetX = 0; + ctx.shadowOffsetY = 0; + @assert ctx.shadowOffsetX === 0; + @assert ctx.shadowOffsetY === 0; + + ctx.shadowOffsetX = 1e6; + ctx.shadowOffsetY = 1e6; + @assert ctx.shadowOffsetX === 1e6; + @assert ctx.shadowOffsetY === 1e6; + +- name: 2d.shadow.attributes.shadowOffset.invalid + testing: + - 2d.shadow.offset.invalid + code: | + ctx.shadowOffsetX = 1; + ctx.shadowOffsetY = 2; + ctx.shadowOffsetX = Infinity; + ctx.shadowOffsetY = Infinity; + @assert ctx.shadowOffsetX === 1; + @assert ctx.shadowOffsetY === 2; + + ctx.shadowOffsetX = 1; + ctx.shadowOffsetY = 2; + ctx.shadowOffsetX = -Infinity; + ctx.shadowOffsetY = -Infinity; + @assert ctx.shadowOffsetX === 1; + @assert ctx.shadowOffsetY === 2; + + ctx.shadowOffsetX = 1; + ctx.shadowOffsetY = 2; + ctx.shadowOffsetX = NaN; + ctx.shadowOffsetY = NaN; + @assert ctx.shadowOffsetX === 1; + @assert ctx.shadowOffsetY === 2; + +- name: 2d.shadow.attributes.shadowColor.initial + testing: + - 2d.shadow.color.initial + code: | + @assert ctx.shadowColor === 'rgba(0, 0, 0, 0)'; + +- name: 2d.shadow.attributes.shadowColor.valid + testing: + - 2d.shadow.color.get + - 2d.shadow.color.set + code: | + ctx.shadowColor = 'lime'; + @assert ctx.shadowColor === '#00ff00'; + + ctx.shadowColor = 'RGBA(0,255, 0,0)'; + @assert ctx.shadowColor === 'rgba(0, 255, 0, 0)'; + +- name: 2d.shadow.attributes.shadowColor.invalid + testing: + - 2d.shadow.color.invalid + code: | + ctx.shadowColor = '#00ff00'; + ctx.shadowColor = 'bogus'; + @assert ctx.shadowColor === '#00ff00'; + + ctx.shadowColor = '#00ff00'; + ctx.shadowColor = 'red bogus'; + @assert ctx.shadowColor === '#00ff00'; + + ctx.shadowColor = '#00ff00'; + ctx.shadowColor = ctx; + @assert ctx.shadowColor === '#00ff00'; + + ctx.shadowColor = '#00ff00'; + ctx.shadowColor = undefined; + @assert ctx.shadowColor === '#00ff00'; + +- name: 2d.shadow.enable.off.1 + desc: Shadows are not drawn when only shadowColor is set + testing: + - 2d.shadow.enable + - 2d.shadow.render + code: | + ctx.shadowColor = '#f00'; + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.enable.off.2 + desc: Shadows are not drawn when only shadowColor is set + testing: + - 2d.shadow.enable + - 2d.shadow.render + code: | + ctx.globalCompositeOperation = 'destination-atop'; + ctx.shadowColor = '#f00'; + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.enable.blur + desc: Shadows are drawn if shadowBlur is set + testing: + - 2d.shadow.enable + - 2d.shadow.render + code: | + ctx.globalCompositeOperation = 'destination-atop'; + ctx.shadowColor = '#0f0'; + ctx.shadowBlur = 0.1; + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.enable.x + desc: Shadows are drawn if shadowOffsetX is set + testing: + - 2d.shadow.enable + - 2d.shadow.render + code: | + ctx.globalCompositeOperation = 'destination-atop'; + ctx.shadowColor = '#0f0'; + ctx.shadowOffsetX = 0.1; + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.enable.y + desc: Shadows are drawn if shadowOffsetY is set + testing: + - 2d.shadow.enable + - 2d.shadow.render + code: | + ctx.globalCompositeOperation = 'destination-atop'; + ctx.shadowColor = '#0f0'; + ctx.shadowOffsetY = 0.1; + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.offset.positiveX + desc: Shadows can be offset with positive x + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.shadowColor = '#0f0'; + ctx.shadowOffsetX = 50; + ctx.fillRect(0, 0, 50, 50); + @assert pixel 25,25 == 0,255,0,255; + @assert pixel 75,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.offset.negativeX + desc: Shadows can be offset with negative x + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.shadowColor = '#0f0'; + ctx.shadowOffsetX = -50; + ctx.fillRect(50, 0, 50, 50); + @assert pixel 25,25 == 0,255,0,255; + @assert pixel 75,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.offset.positiveY + desc: Shadows can be offset with positive y + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.shadowColor = '#0f0'; + ctx.shadowOffsetY = 25; + ctx.fillRect(0, 0, 100, 25); + @assert pixel 50,12 == 0,255,0,255; + @assert pixel 50,37 == 0,255,0,255; + expected: green + +- name: 2d.shadow.offset.negativeY + desc: Shadows can be offset with negative y + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.shadowColor = '#0f0'; + ctx.shadowOffsetY = -25; + ctx.fillRect(0, 25, 100, 25); + @assert pixel 50,12 == 0,255,0,255; + @assert pixel 50,37 == 0,255,0,255; + expected: green + +- name: 2d.shadow.outside + desc: Shadows of shapes outside the visible area can be offset onto the visible area + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowColor = '#0f0'; + ctx.shadowOffsetX = 100; + ctx.fillRect(-100, 0, 25, 50); + ctx.shadowOffsetX = -100; + ctx.fillRect(175, 0, 25, 50); + ctx.shadowOffsetX = 0; + ctx.shadowOffsetY = 100; + ctx.fillRect(25, -100, 50, 25); + ctx.shadowOffsetY = -100; + ctx.fillRect(25, 125, 50, 25); + @assert pixel 12,25 == 0,255,0,255; + @assert pixel 87,25 == 0,255,0,255; + @assert pixel 50,12 == 0,255,0,255; + @assert pixel 50,37 == 0,255,0,255; + expected: green + +- name: 2d.shadow.clip.1 + desc: Shadows of clipped shapes are still drawn within the clipping region + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 50, 50); + ctx.fillStyle = '#f00'; + ctx.fillRect(50, 0, 50, 50); + + ctx.save(); + ctx.beginPath(); + ctx.rect(50, 0, 50, 50); + ctx.clip(); + ctx.shadowColor = '#0f0'; + ctx.shadowOffsetX = 50; + ctx.fillRect(0, 0, 50, 50); + ctx.restore(); + + @assert pixel 25,25 == 0,255,0,255; + @assert pixel 75,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.clip.2 + desc: Shadows are not drawn outside the clipping region + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 50, 50); + ctx.fillStyle = '#0f0'; + ctx.fillRect(50, 0, 50, 50); + + ctx.save(); + ctx.beginPath(); + ctx.rect(0, 0, 50, 50); + ctx.clip(); + ctx.shadowColor = '#f00'; + ctx.shadowOffsetX = 50; + ctx.fillRect(0, 0, 50, 50); + ctx.restore(); + + @assert pixel 25,25 == 0,255,0,255; + @assert pixel 75,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.clip.3 + desc: Shadows of clipped shapes are still drawn within the clipping region + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 50, 50); + ctx.fillStyle = '#0f0'; + ctx.fillRect(50, 0, 50, 50); + + ctx.save(); + ctx.beginPath(); + ctx.rect(0, 0, 50, 50); + ctx.clip(); + ctx.fillStyle = '#f00'; + ctx.shadowColor = '#0f0'; + ctx.shadowOffsetX = 50; + ctx.fillRect(-50, 0, 50, 50); + ctx.restore(); + + @assert pixel 25,25 == 0,255,0,255; + @assert pixel 75,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.stroke.basic + desc: Shadows are drawn for strokes + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#f00'; + ctx.shadowColor = '#0f0'; + ctx.shadowOffsetY = 50; + ctx.beginPath(); + ctx.lineWidth = 50; + ctx.moveTo(0, -25); + ctx.lineTo(100, -25); + ctx.stroke(); + + @assert pixel 1,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.stroke.cap.1 + desc: Shadows are not drawn for areas outside stroke caps + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#f00'; + ctx.shadowColor = '#f00'; + ctx.shadowOffsetY = 50; + ctx.beginPath(); + ctx.lineWidth = 50; + ctx.lineCap = 'butt'; + ctx.moveTo(-50, -25); + ctx.lineTo(0, -25); + ctx.moveTo(100, -25); + ctx.lineTo(150, -25); + ctx.stroke(); + + @assert pixel 1,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.stroke.cap.2 + desc: Shadows are drawn for stroke caps + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#f00'; + ctx.shadowColor = '#0f0'; + ctx.shadowOffsetY = 50; + ctx.beginPath(); + ctx.lineWidth = 50; + ctx.lineCap = 'square'; + ctx.moveTo(25, -25); + ctx.lineTo(75, -25); + ctx.stroke(); + + @assert pixel 1,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.stroke.join.1 + desc: Shadows are not drawn for areas outside stroke joins + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#f00'; + ctx.shadowColor = '#f00'; + ctx.shadowOffsetX = 100; + ctx.lineWidth = 200; + ctx.lineJoin = 'bevel'; + ctx.beginPath(); + ctx.moveTo(-200, -50); + ctx.lineTo(-150, -50); + ctx.lineTo(-151, -100); + ctx.stroke(); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 48,48 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.shadow.stroke.join.2 + desc: Shadows are drawn for stroke joins + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 50, 50); + ctx.fillStyle = '#0f0'; + ctx.fillRect(50, 0, 50, 50); + ctx.strokeStyle = '#f00'; + ctx.shadowColor = '#0f0'; + ctx.shadowOffsetX = 100; + ctx.lineWidth = 200; + ctx.lineJoin = 'miter'; + ctx.beginPath(); + ctx.moveTo(-200, -50); + ctx.lineTo(-150, -50); + ctx.lineTo(-151, -100); + ctx.stroke(); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 48,48 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.shadow.stroke.join.3 + desc: Shadows are drawn for stroke joins respecting miter limit + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#f00'; + ctx.shadowColor = '#f00'; + ctx.shadowOffsetX = 100; + ctx.lineWidth = 200; + ctx.lineJoin = 'miter'; + ctx.miterLimit = 0.1; + ctx.beginPath(); + ctx.moveTo(-200, -50); + ctx.lineTo(-150, -50); + ctx.lineTo(-151, -100); // (not an exact right angle, to avoid some other bug in Firefox 3) + ctx.stroke(); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 48,48 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.shadow.image.basic + desc: Shadows are drawn for images + testing: + - 2d.shadow.render + images: + - red.png + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowColor = '#0f0'; + ctx.shadowOffsetY = 50; + ctx.drawImage(document.getElementById('red.png'), 0, -50); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.image.transparent.1 + desc: Shadows are not drawn for transparent images + testing: + - 2d.shadow.render + images: + - transparent.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowColor = '#f00'; + ctx.shadowOffsetY = 50; + ctx.drawImage(document.getElementById('transparent.png'), 0, -50); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.image.transparent.2 + desc: Shadows are not drawn for transparent parts of images + testing: + - 2d.shadow.render + images: + - redtransparent.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 50, 50); + ctx.fillStyle = '#f00'; + ctx.fillRect(50, 0, 50, 50); + ctx.shadowOffsetY = 50; + ctx.shadowColor = '#0f0'; + ctx.drawImage(document.getElementById('redtransparent.png'), 50, -50); + ctx.shadowColor = '#f00'; + ctx.drawImage(document.getElementById('redtransparent.png'), -50, -50); + + @assert pixel 25,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 75,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.image.alpha + desc: Shadows are drawn correctly for partially-transparent images + testing: + - 2d.shadow.render + images: + - transparent50.png + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowOffsetY = 50; + ctx.shadowColor = '#00f'; + ctx.drawImage(document.getElementById('transparent50.png'), 0, -50); + + @assert pixel 50,25 ==~ 127,0,127,255; + expected: | + size 100 50 + cr.set_source_rgb(0.5, 0, 0.5) + cr.rectangle(0, 0, 100, 50) + cr.fill() + +- name: 2d.shadow.image.section + desc: Shadows are not drawn for areas outside image source rectangles + testing: + - 2d.shadow.render + images: + - redtransparent.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowOffsetY = 50; + ctx.shadowColor = '#f00'; + ctx.drawImage(document.getElementById('redtransparent.png'), 50, 0, 50, 50, 0, -50, 50, 50); + + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 50,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.shadow.image.scale + desc: Shadows are drawn correctly for scaled images + testing: + - 2d.shadow.render + images: + - redtransparent.png + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowOffsetY = 50; + ctx.shadowColor = '#0f0'; + ctx.drawImage(document.getElementById('redtransparent.png'), 0, 0, 100, 50, -10, -50, 240, 50); + + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 50,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.shadow.canvas.basic + desc: Shadows are drawn for canvases + testing: + - 2d.shadow.render + code: | + var canvas2 = document.createElement('canvas'); + canvas2.width = 100; + canvas2.height = 50; + var ctx2 = canvas2.getContext('2d'); + ctx2.fillStyle = '#f00'; + ctx2.fillRect(0, 0, 100, 50); + + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowColor = '#0f0'; + ctx.shadowOffsetY = 50; + ctx.drawImage(canvas2, 0, -50); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.canvas.transparent.1 + desc: Shadows are not drawn for transparent canvases + testing: + - 2d.shadow.render + code: | + var canvas2 = document.createElement('canvas'); + canvas2.width = 100; + canvas2.height = 50; + var ctx2 = canvas2.getContext('2d'); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowColor = '#f00'; + ctx.shadowOffsetY = 50; + ctx.drawImage(canvas2, 0, -50); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.canvas.transparent.2 + desc: Shadows are not drawn for transparent parts of canvases + testing: + - 2d.shadow.render + code: | + var canvas2 = document.createElement('canvas'); + canvas2.width = 100; + canvas2.height = 50; + var ctx2 = canvas2.getContext('2d'); + ctx2.fillStyle = '#f00'; + ctx2.fillRect(0, 0, 50, 50); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 50, 50); + ctx.fillStyle = '#f00'; + ctx.fillRect(50, 0, 50, 50); + ctx.shadowOffsetY = 50; + ctx.shadowColor = '#0f0'; + ctx.drawImage(canvas2, 50, -50); + ctx.shadowColor = '#f00'; + ctx.drawImage(canvas2, -50, -50); + + @assert pixel 25,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 75,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.canvas.alpha + desc: Shadows are drawn correctly for partially-transparent canvases + testing: + - 2d.shadow.render + images: + - transparent50.png + code: | + var canvas2 = document.createElement('canvas'); + canvas2.width = 100; + canvas2.height = 50; + var ctx2 = canvas2.getContext('2d'); + ctx2.fillStyle = 'rgba(255, 0, 0, 0.5)'; + ctx2.fillRect(0, 0, 100, 50); + + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowOffsetY = 50; + ctx.shadowColor = '#00f'; + ctx.drawImage(canvas2, 0, -50); + + @assert pixel 50,25 ==~ 127,0,127,255; + expected: | + size 100 50 + cr.set_source_rgb(0.5, 0, 0.5) + cr.rectangle(0, 0, 100, 50) + cr.fill() + +- name: 2d.shadow.pattern.basic + desc: Shadows are drawn for fill patterns + testing: + - 2d.shadow.render + # http://bugs.webkit.org/show_bug.cgi?id=15266 + images: + - red.png + code: | + var pattern = ctx.createPattern(document.getElementById('red.png'), 'repeat'); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowColor = '#0f0'; + ctx.shadowOffsetY = 50; + ctx.fillStyle = pattern; + ctx.fillRect(0, -50, 100, 50); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.pattern.transparent.1 + desc: Shadows are not drawn for transparent fill patterns + testing: + - 2d.shadow.render + # http://bugs.webkit.org/show_bug.cgi?id=15266 + images: + - transparent.png + code: | + var pattern = ctx.createPattern(document.getElementById('transparent.png'), 'repeat'); + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowColor = '#f00'; + ctx.shadowOffsetY = 50; + ctx.fillStyle = pattern; + ctx.fillRect(0, -50, 100, 50); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.pattern.transparent.2 + desc: Shadows are not drawn for transparent parts of fill patterns + testing: + - 2d.shadow.render + # http://bugs.webkit.org/show_bug.cgi?id=15266 + images: + - redtransparent.png + code: | + var pattern = ctx.createPattern(document.getElementById('redtransparent.png'), 'repeat'); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 50, 50); + ctx.fillStyle = '#0f0'; + ctx.fillRect(50, 0, 50, 50); + ctx.shadowOffsetY = 50; + ctx.shadowColor = '#0f0'; + ctx.fillStyle = pattern; + ctx.fillRect(0, -50, 100, 50); + + @assert pixel 25,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 75,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.pattern.alpha + desc: Shadows are drawn correctly for partially-transparent fill patterns + testing: + - 2d.shadow.render + # http://bugs.webkit.org/show_bug.cgi?id=15266 + images: + - transparent50.png + code: | + var pattern = ctx.createPattern(document.getElementById('transparent50.png'), 'repeat'); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowOffsetY = 50; + ctx.shadowColor = '#00f'; + ctx.fillStyle = pattern; + ctx.fillRect(0, -50, 100, 50); + + @assert pixel 50,25 ==~ 127,0,127,255; + expected: | + size 100 50 + cr.set_source_rgb(0.5, 0, 0.5) + cr.rectangle(0, 0, 100, 50) + cr.fill() + +- name: 2d.shadow.gradient.basic + desc: Shadows are drawn for gradient fills + testing: + - 2d.shadow.render + # http://bugs.webkit.org/show_bug.cgi?id=15266 + code: | + var gradient = ctx.createLinearGradient(0, 0, 100, 0); + gradient.addColorStop(0, '#f00'); + gradient.addColorStop(1, '#f00'); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowColor = '#0f0'; + ctx.shadowOffsetY = 50; + ctx.fillStyle = gradient; + ctx.fillRect(0, -50, 100, 50); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.gradient.transparent.1 + desc: Shadows are not drawn for transparent gradient fills + testing: + - 2d.shadow.render + # http://bugs.webkit.org/show_bug.cgi?id=15266 + code: | + var gradient = ctx.createLinearGradient(0, 0, 100, 0); + gradient.addColorStop(0, 'rgba(0,0,0,0)'); + gradient.addColorStop(1, 'rgba(0,0,0,0)'); + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowColor = '#f00'; + ctx.shadowOffsetY = 50; + ctx.fillStyle = gradient; + ctx.fillRect(0, -50, 100, 50); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.gradient.transparent.2 + desc: Shadows are not drawn for transparent parts of gradient fills + testing: + - 2d.shadow.render + # http://bugs.webkit.org/show_bug.cgi?id=15266 + code: | + var gradient = ctx.createLinearGradient(0, 0, 100, 0); + gradient.addColorStop(0, '#f00'); + gradient.addColorStop(0.499, '#f00'); + gradient.addColorStop(0.5, 'rgba(0,0,0,0)'); + gradient.addColorStop(1, 'rgba(0,0,0,0)'); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 50, 50); + ctx.fillStyle = '#0f0'; + ctx.fillRect(50, 0, 50, 50); + ctx.shadowOffsetY = 50; + ctx.shadowColor = '#0f0'; + ctx.fillStyle = gradient; + ctx.fillRect(0, -50, 100, 50); + + @assert pixel 25,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 75,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.gradient.alpha + desc: Shadows are drawn correctly for partially-transparent gradient fills + testing: + - 2d.shadow.render + # http://bugs.webkit.org/show_bug.cgi?id=15266 + code: | + var gradient = ctx.createLinearGradient(0, 0, 100, 0); + gradient.addColorStop(0, 'rgba(255,0,0,0.5)'); + gradient.addColorStop(1, 'rgba(255,0,0,0.5)'); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowOffsetY = 50; + ctx.shadowColor = '#00f'; + ctx.fillStyle = gradient; + ctx.fillRect(0, -50, 100, 50); + + @assert pixel 50,25 ==~ 127,0,127,255; + expected: | + size 100 50 + cr.set_source_rgb(0.5, 0, 0.5) + cr.rectangle(0, 0, 100, 50) + cr.fill() + +- name: 2d.shadow.transform.1 + desc: Shadows take account of transformations + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowOffsetY = 50; + ctx.shadowColor = '#0f0'; + ctx.translate(100, 100); + ctx.fillRect(-100, -150, 100, 50); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.transform.2 + desc: Shadow offsets are not affected by transformations + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowOffsetY = 50; + ctx.shadowColor = '#0f0'; + ctx.rotate(Math.PI) + ctx.fillRect(-100, 0, 100, 50); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.shadow.blur.low + desc: Shadows look correct for small blurs + manual: + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#ff0'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowColor = '#00f'; + ctx.shadowOffsetY = 25; + for (var x = 0; x < 100; ++x) { + ctx.save(); + ctx.beginPath(); + ctx.rect(x, 0, 1, 50); + ctx.clip(); + ctx.shadowBlur = x; + ctx.fillRect(-200, -200, 500, 200); + ctx.restore(); + } + expected: | + size 100 50 + import math + cr.set_source_rgb(0, 0, 1) + cr.rectangle(0, 0, 1, 25) + cr.fill() + cr.set_source_rgb(1, 1, 0) + cr.rectangle(0, 25, 1, 25) + cr.fill() + for x in range(1, 100): + sigma = x/2.0 + filter = [math.exp(-i*i / (2*sigma*sigma)) / (math.sqrt(2*math.pi)*sigma) for i in range(-24, 26)] + accum = [0] + for f in filter: + accum.append(accum[-1] + f) + for y in range(0, 50): + cr.set_source_rgb(accum[y], accum[y], 1-accum[y]) + cr.rectangle(x, y, 1, 1) + cr.fill() + +- name: 2d.shadow.blur.high + desc: Shadows look correct for large blurs + manual: + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#ff0'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowColor = '#00f'; + ctx.shadowOffsetY = 0; + ctx.shadowBlur = 100; + ctx.fillRect(-200, -200, 200, 400); + expected: | + size 100 50 + import math + sigma = 100.0/2 + filter = [math.exp(-i*i / (2*sigma*sigma)) / (math.sqrt(2*math.pi)*sigma) for i in range(-200, 100)] + accum = [0] + for f in filter: + accum.append(accum[-1] + f) + for x in range(0, 100): + cr.set_source_rgb(accum[x+200], accum[x+200], 1-accum[x+200]) + cr.rectangle(x, 0, 1, 50) + cr.fill() + +- name: 2d.shadow.alpha.1 + desc: Shadow colour alpha components are used + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowColor = 'rgba(255, 0, 0, 0.01)'; + ctx.shadowOffsetY = 50; + ctx.fillRect(0, -50, 100, 50); + + @assert pixel 50,25 ==~ 0,255,0,255 +/- 4; + expected: green + +- name: 2d.shadow.alpha.2 + desc: Shadow colour alpha components are used + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowColor = 'rgba(0, 0, 255, 0.5)'; + ctx.shadowOffsetY = 50; + ctx.fillRect(0, -50, 100, 50); + + @assert pixel 50,25 ==~ 127,0,127,255; + expected: | + size 100 50 + cr.set_source_rgb(0.5, 0, 0.5) + cr.rectangle(0, 0, 100, 50) + cr.fill() + +- name: 2d.shadow.alpha.3 + desc: Shadows are affected by globalAlpha + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#f00'; // (work around broken Firefox globalAlpha caching) + ctx.shadowColor = '#00f'; + ctx.shadowOffsetY = 50; + ctx.globalAlpha = 0.5; + ctx.fillRect(0, -50, 100, 50); + + @assert pixel 50,25 ==~ 127,0,127,255; + expected: | + size 100 50 + cr.set_source_rgb(0.5, 0, 0.5) + cr.rectangle(0, 0, 100, 50) + cr.fill() + +- name: 2d.shadow.alpha.4 + desc: Shadows with alpha components are correctly affected by globalAlpha + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#f00'; // (work around broken Firefox globalAlpha caching) + ctx.shadowColor = 'rgba(0, 0, 255, 0.707)'; + ctx.shadowOffsetY = 50; + ctx.globalAlpha = 0.707; + ctx.fillRect(0, -50, 100, 50); + + @assert pixel 50,25 ==~ 127,0,127,255; + expected: | + size 100 50 + cr.set_source_rgb(0.5, 0, 0.5) + cr.rectangle(0, 0, 100, 50) + cr.fill() + +- name: 2d.shadow.alpha.5 + desc: Shadows of shapes with alpha components are drawn correctly + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = 'rgba(64, 0, 0, 0.5)'; + ctx.shadowColor = '#00f'; + ctx.shadowOffsetY = 50; + ctx.fillRect(0, -50, 100, 50); + + @assert pixel 50,25 ==~ 127,0,127,255; + expected: | + size 100 50 + cr.set_source_rgb(0.5, 0, 0.5) + cr.rectangle(0, 0, 100, 50) + cr.fill() + +- name: 2d.shadow.composite.1 + desc: Shadows are drawn using globalCompositeOperation + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.globalCompositeOperation = 'xor'; + ctx.shadowColor = '#f00'; + ctx.shadowOffsetX = 100; + ctx.fillStyle = '#0f0'; + ctx.fillRect(-100, 0, 200, 50); + + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.shadow.composite.2 + desc: Shadows are drawn using globalCompositeOperation + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.globalCompositeOperation = 'xor'; + ctx.shadowColor = '#f00'; + ctx.shadowBlur = 1; + ctx.fillStyle = '#0f0'; + ctx.fillRect(-10, -10, 120, 70); + + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.shadow.composite.3 + desc: Areas outside shadows are drawn correctly with destination-out + testing: + - 2d.shadow.render + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.globalCompositeOperation = 'destination-out'; + ctx.shadowColor = '#f00'; + ctx.shadowBlur = 10; + ctx.fillStyle = '#f00'; + ctx.fillRect(200, 0, 100, 50); + + @assert pixel 5,5 ==~ 0,255,0,255; + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + + + + + + +- name: 2d.clearRect.basic + desc: clearRect clears to transparent black + testing: + - 2d.clearRect + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.clearRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,0,0,0; + expected: clear + +- name: 2d.clearRect.path + desc: clearRect does not affect the current path + testing: + - 2d.clearRect + code: | + ctx.fillStyle = '#0f0'; + ctx.beginPath(); + ctx.rect(0, 0, 100, 50); + ctx.clearRect(0, 0, 16, 16); + ctx.fill(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.clearRect.zero + desc: clearRect of zero pixels has no effect + testing: + - 2d.clearRect + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.clearRect(0, 0, 100, 0); + ctx.clearRect(0, 0, 0, 50); + ctx.clearRect(0, 0, 0, 0); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.clearRect.negative + desc: clearRect of negative sizes works + testing: + - 2d.clearRect + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.clearRect(0, 0, 50, 25); + ctx.clearRect(100, 0, -50, 25); + ctx.clearRect(0, 50, 50, -25); + ctx.clearRect(100, 50, -50, -25); + @assert pixel 25,12 == 0,0,0,0; + @assert pixel 75,12 == 0,0,0,0; + @assert pixel 25,37 == 0,0,0,0; + @assert pixel 75,37 == 0,0,0,0; + expected: clear + +- name: 2d.clearRect.transform + desc: clearRect is affected by transforms + testing: + - 2d.clearRect + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.scale(10, 10); + ctx.translate(0, 5); + ctx.clearRect(0, -5, 10, 5); + @assert pixel 50,25 == 0,0,0,0; + expected: clear + +- name: 2d.clearRect.globalalpha + desc: clearRect is not affected by globalAlpha + testing: + - 2d.clearRect + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.globalAlpha = 0.1; + ctx.clearRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,0,0,0; + expected: clear + +- name: 2d.clearRect.globalcomposite + desc: clearRect is not affected by globalCompositeOperation + testing: + - 2d.clearRect + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.globalCompositeOperation = 'destination-atop'; + ctx.clearRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,0,0,0; + expected: clear + +- name: 2d.clearRect.clip + desc: clearRect is affected by clipping regions + testing: + - 2d.clearRect + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.beginPath(); + ctx.rect(0, 0, 16, 16); + ctx.clip(); + + ctx.clearRect(0, 0, 100, 50); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 16, 16); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.clearRect.shadow + desc: clearRect does not draw shadows + testing: + - 2d.clearRect + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowColor = '#f00'; + ctx.shadowBlur = 0; + ctx.shadowOffsetX = 0; + ctx.shadowOffsetY = 50; + ctx.clearRect(0, -50, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.clearRect.nonfinite + desc: clearRect() with Infinity/NaN is ignored + testing: + - 2d.nonfinite + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + @nonfinite ctx.clearRect(<0 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <100 Infinity -Infinity NaN>, <50 Infinity -Infinity NaN>); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + + +- name: 2d.fillRect.basic + desc: fillRect works + testing: + - 2d.fillRect + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.fillRect.path + desc: fillRect does not affect the current path + testing: + - 2d.fillRect + code: | + ctx.beginPath(); + ctx.rect(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 16, 16); + ctx.fillStyle = '#0f0'; + ctx.fill(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.fillRect.zero + desc: fillRect of zero pixels has no effect + testing: + - 2d.fillRect + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 0); + ctx.fillRect(0, 0, 0, 50); + ctx.fillRect(0, 0, 0, 0); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.fillRect.negative + desc: fillRect of negative sizes works + testing: + - 2d.fillRect + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 50, 25); + ctx.fillRect(100, 0, -50, 25); + ctx.fillRect(0, 50, 50, -25); + ctx.fillRect(100, 50, -50, -25); + @assert pixel 25,12 == 0,255,0,255; + @assert pixel 75,12 == 0,255,0,255; + @assert pixel 25,37 == 0,255,0,255; + @assert pixel 75,37 == 0,255,0,255; + expected: green + +- name: 2d.fillRect.transform + desc: fillRect is affected by transforms + testing: + - 2d.fillRect + code: | + ctx.scale(10, 10); + ctx.translate(0, 5); + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, -5, 10, 5); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +# don't bother testing globalalpha, globalcomposite because they're already heavily used by other test cases + +- name: 2d.fillRect.clip + desc: fillRect is affected by clipping regions + testing: + - 2d.fillRect + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.beginPath(); + ctx.rect(0, 0, 16, 16); + ctx.clip(); + + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 16, 16); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.fillRect.shadow + desc: fillRect draws shadows + testing: + - 2d.fillRect + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.shadowColor = '#0f0'; + ctx.shadowBlur = 0; + ctx.shadowOffsetX = 0; + ctx.shadowOffsetY = 50; + ctx.fillRect(0, -50, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.fillRect.nonfinite + desc: fillRect() with Infinity/NaN is ignored + testing: + - 2d.nonfinite + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.fillStyle = '#f00'; + @nonfinite ctx.fillRect(<0 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <100 Infinity -Infinity NaN>, <50 Infinity -Infinity NaN>); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + + +- name: 2d.strokeRect.basic + desc: strokeRect works + testing: + - 2d.strokeRect + code: | + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 50; + ctx.strokeRect(25, 24, 50, 2); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.strokeRect.path + desc: strokeRect does not affect the current path + testing: + - 2d.strokeRect + code: | + ctx.beginPath(); + ctx.rect(0, 0, 100, 50); + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 5; + ctx.strokeRect(0, 0, 16, 16); + ctx.fillStyle = '#0f0'; + ctx.fill(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.strokeRect.zero.1 + desc: strokeRect of 0x0 pixels draws nothing + testing: + - 2d.strokeRect + code: | + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 250; + ctx.strokeRect(50, 25, 0, 0); + @assert pixel 50,25 == 0,0,0,0; + expected: clear + +- name: 2d.strokeRect.zero.2 + desc: strokeRect of 0x0 pixels draws nothing, including caps and joins + testing: + - 2d.strokeRect + code: | + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 250; + ctx.lineCap = 'round'; + ctx.lineJoin = 'round'; + ctx.strokeRect(50, 25, 0, 0); + @assert pixel 50,25 == 0,0,0,0; + expected: clear + +- name: 2d.strokeRect.zero.3 + desc: strokeRect of Nx0 pixels draws a straight line + testing: + - 2d.strokeRect + code: | + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 50; + ctx.strokeRect(0, 25, 100, 0); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.strokeRect.zero.4 + desc: strokeRect of Nx0 pixels draws a closed line with no caps + testing: + - 2d.strokeRect + code: | + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 250; + ctx.lineCap = 'round'; + ctx.strokeRect(100, 25, 100, 0); + @assert pixel 50,25 == 0,0,0,0; + expected: clear + +- name: 2d.strokeRect.zero.5 + desc: strokeRect of Nx0 pixels draws a closed line with joins + testing: + - 2d.strokeRect + code: | + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 250; + ctx.lineJoin = 'round'; + ctx.strokeRect(100, 25, 100, 0); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.strokeRect.negative + desc: strokeRect of negative sizes works + testing: + - 2d.strokeRect + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 25; + ctx.strokeRect(12, 12, 26, 1); + ctx.strokeRect(88, 12, -26, 1); + ctx.strokeRect(12, 38, 26, -1); + ctx.strokeRect(88, 38, -26, -1); + @assert pixel 25,12 == 0,255,0,255; + @assert pixel 75,12 == 0,255,0,255; + @assert pixel 25,37 == 0,255,0,255; + @assert pixel 75,37 == 0,255,0,255; + expected: green + +- name: 2d.strokeRect.transform + desc: fillRect is affected by transforms + testing: + - 2d.strokeRect + code: | + ctx.scale(10, 10); + ctx.translate(0, 5); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 5; + ctx.strokeRect(2.5, -2.6, 5, 0.2); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.strokeRect.globalalpha + desc: strokeRect is affected by globalAlpha + testing: + - 2d.strokeRect + code: | + ctx.globalAlpha = 0; + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 50; + ctx.strokeRect(25, 24, 50, 2); + @assert pixel 50,25 == 0,0,0,0; + expected: clear + +- name: 2d.strokeRect.globalcomposite + desc: strokeRect is not affected by globalCompositeOperation + testing: + - 2d.strokeRect + code: | + ctx.globalCompositeOperation = 'source-in'; + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 50; + ctx.strokeRect(25, 24, 50, 2); + @assert pixel 50,25 == 0,0,0,0; + expected: clear + +- name: 2d.strokeRect.clip + desc: strokeRect is affected by clipping regions + testing: + - 2d.strokeRect + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.beginPath(); + ctx.rect(0, 0, 16, 16); + ctx.clip(); + + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 50; + ctx.strokeRect(0, 0, 100, 50); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 16, 16); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.strokeRect.shadow + desc: strokeRect draws shadows + testing: + - 2d.strokeRect + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.shadowColor = '#0f0'; + ctx.shadowBlur = 0; + ctx.shadowOffsetX = 0; + ctx.shadowOffsetY = 50; + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 50; + ctx.strokeRect(0, -75, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.strokeRect.nonfinite + desc: strokeRect() with Infinity/NaN is ignored + testing: + - 2d.nonfinite + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 150; + @nonfinite ctx.strokeRect(<0 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <100 Infinity -Infinity NaN>, <50 Infinity -Infinity NaN>); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + + +- name: 2d.path.initial + testing: + - 2d.path.initial + #mozilla: { bug: TODO } + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.closePath(); + ctx.fillStyle = '#f00'; + ctx.fill(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.beginPath + testing: + - 2d.path.beginPath + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.rect(0, 0, 100, 50); + ctx.beginPath(); + ctx.fillStyle = '#f00'; + ctx.fill(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.moveTo.basic + testing: + - 2d.path.moveTo + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.rect(0, 0, 10, 50); + ctx.moveTo(100, 0); + ctx.lineTo(10, 0); + ctx.lineTo(10, 50); + ctx.lineTo(100, 50); + ctx.fillStyle = '#0f0'; + ctx.fill(); + @assert pixel 90,25 == 0,255,0,255; + expected: green + +- name: 2d.path.moveTo.newsubpath + testing: + - 2d.path.moveTo + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.beginPath(); + ctx.moveTo(0, 0); + ctx.moveTo(100, 0); + ctx.moveTo(100, 50); + ctx.moveTo(0, 50); + ctx.fillStyle = '#f00'; + ctx.fill(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.moveTo.multiple + testing: + - 2d.path.moveTo + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.moveTo(0, 25); + ctx.moveTo(100, 25); + ctx.moveTo(0, 25); + ctx.lineTo(100, 25); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 50; + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.moveTo.nonfinite + desc: moveTo() with Infinity/NaN is ignored + testing: + - 2d.nonfinite + code: | + ctx.moveTo(0, 0); + ctx.lineTo(100, 0); + @nonfinite ctx.moveTo(<0 Infinity -Infinity NaN>, <50 Infinity -Infinity NaN>); + ctx.lineTo(100, 50); + ctx.lineTo(0, 50); + ctx.fillStyle = '#0f0'; + ctx.fill(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.closePath.empty + testing: + - 2d.path.closePath.empty + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.closePath(); + ctx.fillStyle = '#f00'; + ctx.fill(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.closePath.newline + testing: + - 2d.path.closePath.nonempty + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 50; + ctx.moveTo(-100, 25); + ctx.lineTo(-100, -100); + ctx.lineTo(200, -100); + ctx.lineTo(200, 25); + ctx.closePath(); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.closePath.nextpoint + testing: + - 2d.path.closePath.nonempty + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 50; + ctx.moveTo(-100, 25); + ctx.lineTo(-100, -1000); + ctx.closePath(); + ctx.lineTo(1000, 25); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.lineTo.ensuresubpath.1 + desc: If there is no subpath, the point is added and nothing is drawn + testing: + - 2d.path.lineTo.empty + - 2d.path.ensure + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 50; + ctx.beginPath(); + ctx.lineTo(100, 50); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.lineTo.ensuresubpath.2 + desc: If there is no subpath, the point is added and used for subsequent drawing + testing: + - 2d.path.lineTo.empty + - 2d.path.ensure + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 50; + ctx.beginPath(); + ctx.lineTo(0, 25); + ctx.lineTo(100, 25); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.lineTo.basic + testing: + - 2d.path.lineTo.nonempty + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 50; + ctx.beginPath(); + ctx.moveTo(0, 25); + ctx.lineTo(100, 25); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.lineTo.nextpoint + testing: + - 2d.path.lineTo.nonempty + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 50; + ctx.beginPath(); + ctx.moveTo(-100, -100); + ctx.lineTo(0, 25); + ctx.lineTo(100, 25); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.lineTo.nonfinite + desc: lineTo() with Infinity/NaN is ignored + testing: + - 2d.nonfinite + code: | + ctx.moveTo(0, 0); + ctx.lineTo(100, 0); + @nonfinite ctx.lineTo(<0 Infinity -Infinity NaN>, <50 Infinity -Infinity NaN>); + ctx.lineTo(100, 50); + ctx.lineTo(0, 50); + ctx.fillStyle = '#0f0'; + ctx.fill(); + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 90,45 == 0,255,0,255; + expected: green + +- name: 2d.path.lineTo.nonfinite.details + desc: lineTo() with Infinity/NaN for first arg still converts the second arg + testing: + - 2d.nonfinite + code: | + for (var arg1 of [Infinity, -Infinity, NaN]) { + var converted = false; + ctx.lineTo(arg1, { valueOf: function() { converted = true; return 0; } }); + @assert converted; + } + expected: clear + +- name: 2d.path.quadraticCurveTo.ensuresubpath.1 + desc: If there is no subpath, the first control point is added (and nothing is drawn up to it) + testing: + - 2d.path.quadratic.empty + - 2d.path.ensure + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 50; + ctx.beginPath(); + ctx.quadraticCurveTo(100, 50, 200, 50); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 95,45 == 0,255,0,255; @moz-todo + expected: green + +- name: 2d.path.quadraticCurveTo.ensuresubpath.2 + desc: If there is no subpath, the first control point is added + testing: + - 2d.path.quadratic.empty + - 2d.path.ensure + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 50; + ctx.beginPath(); + ctx.quadraticCurveTo(0, 25, 100, 25); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 5,45 == 0,255,0,255; @moz-todo + expected: green + +- name: 2d.path.quadraticCurveTo.basic + testing: + - 2d.path.quadratic.nonempty + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 50; + ctx.beginPath(); + ctx.moveTo(0, 25); + ctx.quadraticCurveTo(100, 25, 100, 25); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.quadraticCurveTo.shape + testing: + - 2d.path.quadratic.nonempty + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 55; + ctx.beginPath(); + ctx.moveTo(-1000, 1050); + ctx.quadraticCurveTo(0, -1000, 1200, 1050); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.path.quadraticCurveTo.scaled + testing: + - 2d.path.quadratic.nonempty + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.scale(1000, 1000); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 0.055; + ctx.beginPath(); + ctx.moveTo(-1, 1.05); + ctx.quadraticCurveTo(0, -1, 1.2, 1.05); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.path.quadraticCurveTo.nonfinite + desc: quadraticCurveTo() with Infinity/NaN is ignored + testing: + - 2d.nonfinite + code: | + ctx.moveTo(0, 0); + ctx.lineTo(100, 0); + @nonfinite ctx.quadraticCurveTo(<0 Infinity -Infinity NaN>, <50 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <50 Infinity -Infinity NaN>); + ctx.lineTo(100, 50); + ctx.lineTo(0, 50); + ctx.fillStyle = '#0f0'; + ctx.fill(); + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 90,45 == 0,255,0,255; + expected: green + +- name: 2d.path.bezierCurveTo.ensuresubpath.1 + desc: If there is no subpath, the first control point is added (and nothing is drawn up to it) + testing: + - 2d.path.bezier.empty + - 2d.path.ensure + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 50; + ctx.beginPath(); + ctx.bezierCurveTo(100, 50, 200, 50, 200, 50); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 95,45 == 0,255,0,255; + expected: green + +- name: 2d.path.bezierCurveTo.ensuresubpath.2 + desc: If there is no subpath, the first control point is added + testing: + - 2d.path.bezier.empty + - 2d.path.ensure + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 50; + ctx.beginPath(); + ctx.bezierCurveTo(0, 25, 100, 25, 100, 25); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 5,45 == 0,255,0,255; + expected: green + +- name: 2d.path.bezierCurveTo.basic + testing: + - 2d.path.bezier.nonempty + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 50; + ctx.beginPath(); + ctx.moveTo(0, 25); + ctx.bezierCurveTo(100, 25, 100, 25, 100, 25); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.bezierCurveTo.shape + testing: + - 2d.path.bezier.nonempty + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 55; + ctx.beginPath(); + ctx.moveTo(-2000, 3100); + ctx.bezierCurveTo(-2000, -1000, 2100, -1000, 2100, 3100); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.path.bezierCurveTo.scaled + testing: + - 2d.path.bezier.nonempty + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.scale(1000, 1000); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 0.055; + ctx.beginPath(); + ctx.moveTo(-2, 3.1); + ctx.bezierCurveTo(-2, -1, 2.1, -1, 2.1, 3.1); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.path.bezierCurveTo.nonfinite + desc: bezierCurveTo() with Infinity/NaN is ignored + testing: + - 2d.nonfinite + code: | + ctx.moveTo(0, 0); + ctx.lineTo(100, 0); + @nonfinite ctx.bezierCurveTo(<0 Infinity -Infinity NaN>, <50 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <50 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <50 Infinity -Infinity NaN>); + ctx.lineTo(100, 50); + ctx.lineTo(0, 50); + ctx.fillStyle = '#0f0'; + ctx.fill(); + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 90,45 == 0,255,0,255; + expected: green + +- name: 2d.path.arcTo.ensuresubpath.1 + desc: If there is no subpath, the first control point is added (and nothing is drawn up to it) + testing: + - 2d.path.arcTo.empty + - 2d.path.ensure + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.lineWidth = 50; + ctx.strokeStyle = '#f00'; + ctx.beginPath(); + ctx.arcTo(100, 50, 200, 50, 0.1); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.arcTo.ensuresubpath.2 + desc: If there is no subpath, the first control point is added + testing: + - 2d.path.arcTo.empty + - 2d.path.ensure + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.lineWidth = 50; + ctx.strokeStyle = '#0f0'; + ctx.beginPath(); + ctx.arcTo(0, 25, 50, 250, 0.1); // adds (x1,y1), draws nothing + ctx.lineTo(100, 25); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.arcTo.coincide.1 + desc: arcTo() has no effect if P0 = P1 + testing: + - 2d.path.arcTo.coincide.01 + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.lineWidth = 50; + + ctx.strokeStyle = '#0f0'; + ctx.beginPath(); + ctx.moveTo(0, 25); + ctx.arcTo(0, 25, 50, 1000, 1); + ctx.lineTo(100, 25); + ctx.stroke(); + + ctx.strokeStyle = '#f00'; + ctx.beginPath(); + ctx.moveTo(50, 25); + ctx.arcTo(50, 25, 100, 25, 1); + ctx.stroke(); + + @assert pixel 50,1 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 50,48 == 0,255,0,255; + expected: green + +- name: 2d.path.arcTo.coincide.2 + desc: arcTo() draws a straight line to P1 if P1 = P2 + testing: + - 2d.path.arcTo.coincide.12 + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.lineWidth = 50; + ctx.strokeStyle = '#0f0'; + ctx.beginPath(); + ctx.moveTo(0, 25); + ctx.arcTo(100, 25, 100, 25, 1); + ctx.stroke(); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.arcTo.collinear.1 + desc: arcTo() with all points on a line, and P1 between P0/P2, draws a straight line to P1 + testing: + - 2d.path.arcTo.collinear + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.lineWidth = 50; + + ctx.strokeStyle = '#0f0'; + ctx.beginPath(); + ctx.moveTo(0, 25); + ctx.arcTo(100, 25, 200, 25, 1); + ctx.stroke(); + + ctx.strokeStyle = '#f00'; + ctx.beginPath(); + ctx.moveTo(-100, 25); + ctx.arcTo(0, 25, 100, 25, 1); + ctx.stroke(); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.arcTo.collinear.2 + desc: arcTo() with all points on a line, and P2 between P0/P1, draws a straight line to P1 + testing: + - 2d.path.arcTo.collinear + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.lineWidth = 50; + + ctx.strokeStyle = '#0f0'; + ctx.beginPath(); + ctx.moveTo(0, 25); + ctx.arcTo(100, 25, 10, 25, 1); + ctx.stroke(); + + ctx.strokeStyle = '#f00'; + ctx.beginPath(); + ctx.moveTo(100, 25); + ctx.arcTo(200, 25, 110, 25, 1); + ctx.stroke(); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.arcTo.collinear.3 + desc: arcTo() with all points on a line, and P0 between P1/P2, draws a straight line to P1 + testing: + - 2d.path.arcTo.collinear + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.lineWidth = 50; + + ctx.strokeStyle = '#0f0'; + ctx.beginPath(); + ctx.moveTo(0, 25); + ctx.arcTo(100, 25, -100, 25, 1); + ctx.stroke(); + + ctx.strokeStyle = '#f00'; + ctx.beginPath(); + ctx.moveTo(100, 25); + ctx.arcTo(200, 25, 0, 25, 1); + ctx.stroke(); + + ctx.beginPath(); + ctx.moveTo(-100, 25); + ctx.arcTo(0, 25, -200, 25, 1); + ctx.stroke(); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.arcTo.shape.curve1 + desc: arcTo() curves in the right kind of shape + testing: + - 2d.path.arcTo.shape + code: | + var tol = 1.5; // tolerance to avoid antialiasing artifacts + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 10; + ctx.beginPath(); + ctx.moveTo(10, 25); + ctx.arcTo(75, 25, 75, 60, 20); + ctx.stroke(); + + ctx.fillStyle = '#0f0'; + ctx.beginPath(); + ctx.rect(10, 20, 45, 10); + ctx.moveTo(80, 45); + ctx.arc(55, 45, 25+tol, 0, -Math.PI/2, true); + ctx.arc(55, 45, 15-tol, -Math.PI/2, 0, false); + ctx.fill(); + + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 55,19 == 0,255,0,255; + @assert pixel 55,20 == 0,255,0,255; + @assert pixel 55,21 == 0,255,0,255; + @assert pixel 64,22 == 0,255,0,255; + @assert pixel 65,21 == 0,255,0,255; + @assert pixel 72,28 == 0,255,0,255; + @assert pixel 73,27 == 0,255,0,255; + @assert pixel 78,36 == 0,255,0,255; + @assert pixel 79,35 == 0,255,0,255; + @assert pixel 80,44 == 0,255,0,255; + @assert pixel 80,45 == 0,255,0,255; + @assert pixel 80,46 == 0,255,0,255; + @assert pixel 65,45 == 0,255,0,255; + expected: green + +- name: 2d.path.arcTo.shape.curve2 + desc: arcTo() curves in the right kind of shape + testing: + - 2d.path.arcTo.shape + code: | + var tol = 1.5; // tolerance to avoid antialiasing artifacts + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.fillStyle = '#f00'; + ctx.beginPath(); + ctx.rect(10, 20, 45, 10); + ctx.moveTo(80, 45); + ctx.arc(55, 45, 25-tol, 0, -Math.PI/2, true); + ctx.arc(55, 45, 15+tol, -Math.PI/2, 0, false); + ctx.fill(); + + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 10; + ctx.beginPath(); + ctx.moveTo(10, 25); + ctx.arcTo(75, 25, 75, 60, 20); + ctx.stroke(); + + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 55,19 == 0,255,0,255; + @assert pixel 55,20 == 0,255,0,255; + @assert pixel 55,21 == 0,255,0,255; + @assert pixel 64,22 == 0,255,0,255; + @assert pixel 65,21 == 0,255,0,255; + @assert pixel 72,28 == 0,255,0,255; + @assert pixel 73,27 == 0,255,0,255; + @assert pixel 78,36 == 0,255,0,255; + @assert pixel 79,35 == 0,255,0,255; + @assert pixel 80,44 == 0,255,0,255; + @assert pixel 80,45 == 0,255,0,255; + @assert pixel 80,46 == 0,255,0,255; + expected: green + +- name: 2d.path.arcTo.shape.start + desc: arcTo() draws a straight line from P0 to P1 + testing: + - 2d.path.arcTo.shape + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 50; + ctx.beginPath(); + ctx.moveTo(0, 25); + ctx.arcTo(200, 25, 200, 50, 10); + ctx.stroke(); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.path.arcTo.shape.end + desc: arcTo() does not draw anything from P1 to P2 + testing: + - 2d.path.arcTo.shape + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 50; + ctx.beginPath(); + ctx.moveTo(-100, -100); + ctx.arcTo(-100, 25, 200, 25, 10); + ctx.stroke(); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.path.arcTo.negative + desc: arcTo() with negative radius throws an exception + testing: + - 2d.path.arcTo.negative + code: | + @assert throws INDEX_SIZE_ERR ctx.arcTo(0, 0, 0, 0, -1); + +- name: 2d.path.arcTo.zero.1 + desc: arcTo() with zero radius draws a straight line from P0 to P1 + testing: + - 2d.path.arcTo.zeroradius + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.lineWidth = 50; + + ctx.strokeStyle = '#0f0'; + ctx.beginPath(); + ctx.moveTo(0, 25); + ctx.arcTo(100, 25, 100, 100, 0); + ctx.stroke(); + + ctx.strokeStyle = '#f00'; + ctx.beginPath(); + ctx.moveTo(0, -25); + ctx.arcTo(50, -25, 50, 50, 0); + ctx.stroke(); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.arcTo.zero.2 + desc: arcTo() with zero radius draws a straight line from P0 to P1, even when all points are collinear + testing: + - 2d.path.arcTo.zeroradius + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.lineWidth = 50; + + ctx.strokeStyle = '#0f0'; + ctx.beginPath(); + ctx.moveTo(0, 25); + ctx.arcTo(100, 25, -100, 25, 0); + ctx.stroke(); + + ctx.strokeStyle = '#f00'; + ctx.beginPath(); + ctx.moveTo(100, 25); + ctx.arcTo(200, 25, 50, 25, 0); + ctx.stroke(); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.arcTo.transformation + desc: arcTo joins up to the last subpath point correctly + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.fillStyle = '#0f0'; + ctx.beginPath(); + ctx.moveTo(0, 50); + ctx.translate(100, 0); + ctx.arcTo(50, 50, 50, 0, 50); + ctx.lineTo(-100, 0); + ctx.fill(); + + @assert pixel 0,0 == 0,255,0,255; + @assert pixel 50,0 == 0,255,0,255; + @assert pixel 99,0 == 0,255,0,255; + @assert pixel 0,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 99,25 == 0,255,0,255; + @assert pixel 0,49 == 0,255,0,255; + @assert pixel 50,49 == 0,255,0,255; + @assert pixel 99,49 == 0,255,0,255; + expected: green + +- name: 2d.path.arcTo.scale + desc: arcTo scales the curve, not just the control points + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.fillStyle = '#0f0'; + ctx.beginPath(); + ctx.moveTo(0, 50); + ctx.translate(100, 0); + ctx.scale(0.1, 1); + ctx.arcTo(50, 50, 50, 0, 50); + ctx.lineTo(-1000, 0); + ctx.fill(); + + @assert pixel 0,0 == 0,255,0,255; + @assert pixel 50,0 == 0,255,0,255; + @assert pixel 99,0 == 0,255,0,255; + @assert pixel 0,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 99,25 == 0,255,0,255; + @assert pixel 0,49 == 0,255,0,255; + @assert pixel 50,49 == 0,255,0,255; + @assert pixel 99,49 == 0,255,0,255; + expected: green + +- name: 2d.path.arcTo.nonfinite + desc: arcTo() with Infinity/NaN is ignored + testing: + - 2d.nonfinite + code: | + ctx.moveTo(0, 0); + ctx.lineTo(100, 0); + @nonfinite ctx.arcTo(<0 Infinity -Infinity NaN>, <50 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <50 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>); + ctx.lineTo(100, 50); + ctx.lineTo(0, 50); + ctx.fillStyle = '#0f0'; + ctx.fill(); + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 90,45 == 0,255,0,255; + expected: green + + +- name: 2d.path.arc.empty + desc: arc() with an empty path does not draw a straight line to the start point + testing: + - 2d.path.arc.nonempty + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.lineWidth = 50; + ctx.strokeStyle = '#f00'; + ctx.beginPath(); + ctx.arc(200, 25, 5, 0, 2*Math.PI, true); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.nonempty + desc: arc() with a non-empty path does draw a straight line to the start point + testing: + - 2d.path.arc.nonempty + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.lineWidth = 50; + ctx.strokeStyle = '#0f0'; + ctx.beginPath(); + ctx.moveTo(0, 25); + ctx.arc(200, 25, 5, 0, 2*Math.PI, true); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.end + desc: arc() adds the end point of the arc to the subpath + testing: + - 2d.path.arc.draw + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.lineWidth = 50; + ctx.strokeStyle = '#0f0'; + ctx.beginPath(); + ctx.moveTo(-100, 0); + ctx.arc(-100, 0, 25, -Math.PI/2, Math.PI/2, true); + ctx.lineTo(100, 25); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.default + desc: arc() with missing last argument defaults to clockwise + testing: + - 2d.path.arc.omitted + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.beginPath(); + ctx.moveTo(100, 0); + ctx.arc(100, 0, 150, -Math.PI, Math.PI/2); + ctx.fill(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.angle.1 + desc: arc() draws pi/2 .. -pi anticlockwise correctly + testing: + - 2d.path.arc.draw + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.beginPath(); + ctx.moveTo(100, 0); + ctx.arc(100, 0, 150, Math.PI/2, -Math.PI, true); + ctx.fill(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.angle.2 + desc: arc() draws -3pi/2 .. -pi anticlockwise correctly + testing: + - 2d.path.arc.draw + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.beginPath(); + ctx.moveTo(100, 0); + ctx.arc(100, 0, 150, -3*Math.PI/2, -Math.PI, true); + ctx.fill(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.angle.3 + desc: arc() wraps angles mod 2pi when anticlockwise and end > start+2pi + testing: + - 2d.path.arc.draw + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.beginPath(); + ctx.moveTo(100, 0); + ctx.arc(100, 0, 150, (512+1/2)*Math.PI, (1024-1)*Math.PI, true); + ctx.fill(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.angle.4 + desc: arc() draws a full circle when clockwise and end > start+2pi + testing: + - 2d.path.arc.draw + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.beginPath(); + ctx.moveTo(50, 25); + ctx.arc(50, 25, 60, (512+1/2)*Math.PI, (1024-1)*Math.PI, false); + ctx.fill(); + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.angle.5 + desc: arc() wraps angles mod 2pi when clockwise and start > end+2pi + testing: + - 2d.path.arc.draw + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.beginPath(); + ctx.moveTo(100, 0); + ctx.arc(100, 0, 150, (1024-1)*Math.PI, (512+1/2)*Math.PI, false); + ctx.fill(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.angle.6 + desc: arc() draws a full circle when anticlockwise and start > end+2pi + testing: + - 2d.path.arc.draw + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.beginPath(); + ctx.moveTo(50, 25); + ctx.arc(50, 25, 60, (1024-1)*Math.PI, (512+1/2)*Math.PI, true); + ctx.fill(); + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.zero.1 + desc: arc() draws nothing when startAngle = endAngle and anticlockwise + testing: + - 2d.path.arc.draw + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 100; + ctx.beginPath(); + ctx.arc(50, 25, 50, 0, 0, true); + ctx.stroke(); + @assert pixel 50,20 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.zero.2 + desc: arc() draws nothing when startAngle = endAngle and clockwise + testing: + - 2d.path.arc.draw + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 100; + ctx.beginPath(); + ctx.arc(50, 25, 50, 0, 0, false); + ctx.stroke(); + @assert pixel 50,20 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.twopie.1 + desc: arc() draws nothing when end = start + 2pi-e and anticlockwise + testing: + - 2d.path.arc.draw + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 100; + ctx.beginPath(); + ctx.arc(50, 25, 50, 0, 2*Math.PI - 1e-4, true); + ctx.stroke(); + @assert pixel 50,20 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.twopie.2 + desc: arc() draws a full circle when end = start + 2pi-e and clockwise + testing: + - 2d.path.arc.draw + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 100; + ctx.beginPath(); + ctx.arc(50, 25, 50, 0, 2*Math.PI - 1e-4, false); + ctx.stroke(); + @assert pixel 50,20 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.twopie.3 + desc: arc() draws a full circle when end = start + 2pi+e and anticlockwise + testing: + - 2d.path.arc.draw + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 100; + ctx.beginPath(); + ctx.arc(50, 25, 50, 0, 2*Math.PI + 1e-4, true); + ctx.stroke(); + @assert pixel 50,20 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.twopie.4 + desc: arc() draws nothing when end = start + 2pi+e and clockwise + testing: + - 2d.path.arc.draw + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 100; + ctx.beginPath(); + ctx.arc(50, 25, 50, 0, 2*Math.PI + 1e-4, false); + ctx.stroke(); + @assert pixel 50,20 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.shape.1 + desc: arc() from 0 to pi does not draw anything in the wrong half + testing: + - 2d.path.arc.draw + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.lineWidth = 50; + ctx.strokeStyle = '#f00'; + ctx.beginPath(); + ctx.arc(50, 50, 50, 0, Math.PI, false); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 20,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.shape.2 + desc: arc() from 0 to pi draws stuff in the right half + testing: + - 2d.path.arc.draw + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.lineWidth = 100; + ctx.strokeStyle = '#0f0'; + ctx.beginPath(); + ctx.arc(50, 50, 50, 0, Math.PI, true); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 20,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.shape.3 + desc: arc() from 0 to -pi/2 does not draw anything in the wrong quadrant + testing: + - 2d.path.arc.draw + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.lineWidth = 100; + ctx.strokeStyle = '#f00'; + ctx.beginPath(); + ctx.arc(0, 50, 50, 0, -Math.PI/2, false); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; @moz-todo + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.shape.4 + desc: arc() from 0 to -pi/2 draws stuff in the right quadrant + testing: + - 2d.path.arc.draw + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.lineWidth = 150; + ctx.strokeStyle = '#0f0'; + ctx.beginPath(); + ctx.arc(-50, 50, 100, 0, -Math.PI/2, true); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.shape.5 + desc: arc() from 0 to 5pi does not draw crazy things + testing: + - 2d.path.arc.draw + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.lineWidth = 200; + ctx.strokeStyle = '#f00'; + ctx.beginPath(); + ctx.arc(300, 0, 100, 0, 5*Math.PI, false); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.selfintersect.1 + desc: arc() with lineWidth > 2*radius is drawn sensibly + testing: + - 2d.path.arc.draw + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.lineWidth = 200; + ctx.strokeStyle = '#f00'; + ctx.beginPath(); + ctx.arc(100, 50, 25, 0, -Math.PI/2, true); + ctx.stroke(); + ctx.beginPath(); + ctx.arc(0, 0, 25, 0, -Math.PI/2, true); + ctx.stroke(); + @assert pixel 1,1 == 0,255,0,255; @moz-todo + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.selfintersect.2 + desc: arc() with lineWidth > 2*radius is drawn sensibly + testing: + - 2d.path.arc.draw + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.lineWidth = 180; + ctx.strokeStyle = '#0f0'; + ctx.beginPath(); + ctx.arc(-50, 50, 25, 0, -Math.PI/2, true); + ctx.stroke(); + ctx.beginPath(); + ctx.arc(100, 0, 25, 0, -Math.PI/2, true); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 90,10 == 0,255,0,255; + @assert pixel 97,1 == 0,255,0,255; + @assert pixel 97,2 == 0,255,0,255; + @assert pixel 97,3 == 0,255,0,255; + @assert pixel 2,48 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.negative + desc: arc() with negative radius throws INDEX_SIZE_ERR + testing: + - 2d.path.arc.negative + code: | + @assert throws INDEX_SIZE_ERR ctx.arc(0, 0, -1, 0, 0, true); + +- name: 2d.path.arc.zeroradius + desc: arc() with zero radius draws a line to the start point + testing: + - 2d.path.arc.zero + code: | + ctx.fillStyle = '#f00' + ctx.fillRect(0, 0, 100, 50); + ctx.lineWidth = 50; + ctx.strokeStyle = '#0f0'; + ctx.beginPath(); + ctx.moveTo(0, 25); + ctx.arc(200, 25, 0, 0, Math.PI, true); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.scale.1 + desc: Non-uniformly scaled arcs are the right shape + testing: + - 2d.path.transformation + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.scale(2, 0.5); + ctx.fillStyle = '#0f0'; + ctx.beginPath(); + ctx.arc(25, 50, 56, 0, 2*Math.PI, false); + ctx.fill(); + ctx.fillStyle = '#f00'; + ctx.beginPath(); + ctx.moveTo(-25, 50); + ctx.arc(-25, 50, 24, 0, 2*Math.PI, false); + ctx.moveTo(75, 50); + ctx.arc(75, 50, 24, 0, 2*Math.PI, false); + ctx.moveTo(25, -25); + ctx.arc(25, -25, 24, 0, 2*Math.PI, false); + ctx.moveTo(25, 125); + ctx.arc(25, 125, 24, 0, 2*Math.PI, false); + ctx.fill(); + + @assert pixel 0,0 == 0,255,0,255; + @assert pixel 50,0 == 0,255,0,255; + @assert pixel 99,0 == 0,255,0,255; + @assert pixel 0,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 99,25 == 0,255,0,255; + @assert pixel 0,49 == 0,255,0,255; + @assert pixel 50,49 == 0,255,0,255; + @assert pixel 99,49 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.scale.2 + desc: Highly scaled arcs are the right shape + testing: + - 2d.path.arc.draw + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.scale(100, 100); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 1.2; + ctx.beginPath(); + ctx.arc(0, 0, 0.6, 0, Math.PI/2, false); + ctx.stroke(); + + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 50,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 98,25 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 50,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.path.arc.nonfinite + desc: arc() with Infinity/NaN is ignored + testing: + - 2d.nonfinite + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.moveTo(0, 0); + ctx.lineTo(100, 0); + @nonfinite ctx.arc(<0 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <50 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <2*Math.PI Infinity -Infinity NaN>, ); + ctx.lineTo(100, 50); + ctx.lineTo(0, 50); + ctx.fillStyle = '#0f0'; + ctx.fill(); + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 90,45 == 0,255,0,255; + expected: green + + +- name: 2d.path.rect.basic + testing: + - 2d.path.rect.subpath + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.rect(0, 0, 100, 50); + ctx.fill(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.rect.newsubpath + testing: + - 2d.path.rect.subpath + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.beginPath(); + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 50; + ctx.moveTo(-100, 25); + ctx.lineTo(-50, 25); + ctx.rect(200, 25, 1, 1); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.rect.closed + testing: + - 2d.path.rect.closed + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 200; + ctx.lineJoin = 'miter'; + ctx.rect(100, 50, 100, 100); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.rect.end.1 + testing: + - 2d.path.rect.newsubpath + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 100; + ctx.rect(200, 100, 400, 1000); + ctx.lineTo(-2000, -1000); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.rect.end.2 + testing: + - 2d.path.rect.newsubpath + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 450; + ctx.lineCap = 'round'; + ctx.lineJoin = 'bevel'; + ctx.rect(150, 150, 2000, 2000); + ctx.lineTo(160, 160); + ctx.stroke(); + @assert pixel 1,1 == 0,255,0,255; + @assert pixel 98,1 == 0,255,0,255; + @assert pixel 1,48 == 0,255,0,255; + @assert pixel 98,48 == 0,255,0,255; + expected: green + +- name: 2d.path.rect.zero.1 + testing: + - 2d.path.rect.subpath + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 100; + ctx.beginPath(); + ctx.rect(0, 50, 100, 0); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.rect.zero.2 + testing: + - 2d.path.rect.subpath + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 100; + ctx.beginPath(); + ctx.rect(50, -100, 0, 250); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.rect.zero.3 + testing: + - 2d.path.rect.subpath + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 100; + ctx.beginPath(); + ctx.rect(50, 25, 0, 0); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.rect.zero.4 + testing: + - 2d.path.rect.subpath + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 50; + ctx.rect(100, 25, 0, 0); + ctx.lineTo(0, 25); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.rect.zero.5 + testing: + - 2d.path.rect.subpath + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 50; + ctx.moveTo(0, 0); + ctx.rect(100, 25, 0, 0); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.rect.zero.6 + testing: + - 2d.path.rect.subpath + #mozilla: { bug: TODO } + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#f00'; + ctx.lineJoin = 'miter'; + ctx.miterLimit = 1.5; + ctx.lineWidth = 200; + ctx.beginPath(); + ctx.rect(100, 25, 1000, 0); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; @moz-todo + expected: green + +- name: 2d.path.rect.negative + testing: + - 2d.path.rect.subpath + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.beginPath(); + ctx.fillStyle = '#0f0'; + ctx.rect(0, 0, 50, 25); + ctx.rect(100, 0, -50, 25); + ctx.rect(0, 50, 50, -25); + ctx.rect(100, 50, -50, -25); + ctx.fill(); + @assert pixel 25,12 == 0,255,0,255; + @assert pixel 75,12 == 0,255,0,255; + @assert pixel 25,37 == 0,255,0,255; + @assert pixel 75,37 == 0,255,0,255; + +- name: 2d.path.rect.winding + testing: + - 2d.path.rect.subpath + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.beginPath(); + ctx.fillStyle = '#f00'; + ctx.rect(0, 0, 50, 50); + ctx.rect(100, 50, -50, -50); + ctx.rect(0, 25, 100, -25); + ctx.rect(100, 25, -100, 25); + ctx.fill(); + @assert pixel 25,12 == 0,255,0,255; + @assert pixel 75,12 == 0,255,0,255; + @assert pixel 25,37 == 0,255,0,255; + @assert pixel 75,37 == 0,255,0,255; + +- name: 2d.path.rect.selfintersect + #mozilla: { bug: TODO } + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 90; + ctx.beginPath(); + ctx.rect(45, 20, 10, 10); + ctx.stroke(); + @assert pixel 50,25 == 0,255,0,255; @moz-todo + expected: green + +- name: 2d.path.rect.nonfinite + desc: rect() with Infinity/NaN is ignored + testing: + - 2d.nonfinite + code: | + ctx.moveTo(0, 0); + ctx.lineTo(100, 0); + @nonfinite ctx.rect(<0 Infinity -Infinity NaN>, <50 Infinity -Infinity NaN>, <1 Infinity -Infinity NaN>, <1 Infinity -Infinity NaN>); + ctx.lineTo(100, 50); + ctx.lineTo(0, 50); + ctx.fillStyle = '#0f0'; + ctx.fill(); + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 90,45 == 0,255,0,255; + expected: green + +- name: 2d.path.fill.overlap + testing: + - 2d.path.fill.basic + code: | + ctx.fillStyle = '#000'; + ctx.fillRect(0, 0, 100, 50); + + ctx.fillStyle = 'rgba(0, 255, 0, 0.5)'; + ctx.rect(0, 0, 100, 50); + ctx.closePath(); + ctx.rect(10, 10, 80, 30); + ctx.fill(); + + @assert pixel 50,25 ==~ 0,127,0,255 +/- 1; + expected: | + size 100 50 + cr.set_source_rgb(0, 0.5, 0) + cr.rectangle(0, 0, 100, 50) + cr.fill() + +- name: 2d.path.fill.winding.add + testing: + - 2d.path.fill.basic + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.fillStyle = '#0f0'; + ctx.moveTo(-10, -10); + ctx.lineTo(110, -10); + ctx.lineTo(110, 60); + ctx.lineTo(-10, 60); + ctx.lineTo(-10, -10); + ctx.lineTo(0, 0); + ctx.lineTo(100, 0); + ctx.lineTo(100, 50); + ctx.lineTo(0, 50); + ctx.fill(); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.fill.winding.subtract.1 + testing: + - 2d.path.fill.basic + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.fillStyle = '#f00'; + ctx.moveTo(-10, -10); + ctx.lineTo(110, -10); + ctx.lineTo(110, 60); + ctx.lineTo(-10, 60); + ctx.lineTo(-10, -10); + ctx.lineTo(0, 0); + ctx.lineTo(0, 50); + ctx.lineTo(100, 50); + ctx.lineTo(100, 0); + ctx.fill(); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.fill.winding.subtract.2 + testing: + - 2d.path.fill.basic + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.fillStyle = '#f00'; + ctx.moveTo(-10, -10); + ctx.lineTo(110, -10); + ctx.lineTo(110, 60); + ctx.lineTo(-10, 60); + ctx.moveTo(0, 0); + ctx.lineTo(0, 50); + ctx.lineTo(100, 50); + ctx.lineTo(100, 0); + ctx.fill(); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.fill.winding.subtract.3 + testing: + - 2d.path.fill.basic + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.fillStyle = '#0f0'; + ctx.moveTo(-10, -10); + ctx.lineTo(110, -10); + ctx.lineTo(110, 60); + ctx.lineTo(-10, 60); + ctx.lineTo(-10, -10); + ctx.lineTo(-20, -20); + ctx.lineTo(120, -20); + ctx.lineTo(120, 70); + ctx.lineTo(-20, 70); + ctx.lineTo(-20, -20); + ctx.lineTo(0, 0); + ctx.lineTo(0, 50); + ctx.lineTo(100, 50); + ctx.lineTo(100, 0); + ctx.fill(); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.fill.closed.basic + testing: + - 2d.path.fill.closed + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.fillStyle = '#0f0'; + ctx.moveTo(0, 0); + ctx.lineTo(100, 0); + ctx.lineTo(100, 50); + ctx.lineTo(0, 50); + ctx.fill(); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.fill.closed.unaffected + testing: + - 2d.path.fill.closed + code: | + ctx.fillStyle = '#00f'; + ctx.fillRect(0, 0, 100, 50); + + ctx.moveTo(0, 0); + ctx.lineTo(100, 0); + ctx.lineTo(100, 50); + ctx.fillStyle = '#f00'; + ctx.fill(); + ctx.lineTo(0, 50); + ctx.fillStyle = '#0f0'; + ctx.fill(); + + @assert pixel 90,10 == 0,255,0,255; + @assert pixel 10,40 == 0,255,0,255; + expected: green + +- name: 2d.path.stroke.overlap + desc: Stroked subpaths are combined before being drawn + testing: + - 2d.path.stroke.basic + code: | + ctx.fillStyle = '#000'; + ctx.fillRect(0, 0, 100, 50); + + ctx.strokeStyle = 'rgba(0, 255, 0, 0.5)'; + ctx.lineWidth = 50; + ctx.moveTo(0, 20); + ctx.lineTo(100, 20); + ctx.moveTo(0, 30); + ctx.lineTo(100, 30); + ctx.stroke(); + + @assert pixel 50,25 ==~ 0,127,0,255 +/- 1; + expected: | + size 100 50 + cr.set_source_rgb(0, 0.5, 0) + cr.rectangle(0, 0, 100, 50) + cr.fill() + +- name: 2d.path.stroke.union + desc: Strokes in opposite directions are unioned, not subtracted + testing: + - 2d.path.stroke.basic + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 40; + ctx.moveTo(0, 10); + ctx.lineTo(100, 10); + ctx.moveTo(100, 40); + ctx.lineTo(0, 40); + ctx.stroke(); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.stroke.unaffected + desc: Stroking does not start a new path or subpath + testing: + - 2d.path.stroke.basic + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.lineWidth = 50; + ctx.moveTo(-100, 25); + ctx.lineTo(-100, -100); + ctx.lineTo(200, -100); + ctx.lineTo(200, 25); + ctx.strokeStyle = '#f00'; + ctx.stroke(); + + ctx.closePath(); + ctx.strokeStyle = '#0f0'; + ctx.stroke(); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.stroke.scale1 + desc: Stroke line widths are scaled by the current transformation matrix + testing: + - 2d.path.transformation + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.beginPath(); + ctx.rect(25, 12.5, 50, 25); + ctx.save(); + ctx.scale(50, 25); + ctx.strokeStyle = '#0f0'; + ctx.stroke(); + ctx.restore(); + + ctx.beginPath(); + ctx.rect(-25, -12.5, 150, 75); + ctx.save(); + ctx.scale(50, 25); + ctx.strokeStyle = '#f00'; + ctx.stroke(); + ctx.restore(); + + @assert pixel 0,0 == 0,255,0,255; + @assert pixel 50,0 == 0,255,0,255; + @assert pixel 99,0 == 0,255,0,255; + @assert pixel 0,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 99,25 == 0,255,0,255; + @assert pixel 0,49 == 0,255,0,255; + @assert pixel 50,49 == 0,255,0,255; + @assert pixel 99,49 == 0,255,0,255; + expected: green + +- name: 2d.path.stroke.scale2 + desc: Stroke line widths are scaled by the current transformation matrix + testing: + - 2d.path.transformation + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.beginPath(); + ctx.rect(25, 12.5, 50, 25); + ctx.save(); + ctx.rotate(Math.PI/2); + ctx.scale(25, 50); + ctx.strokeStyle = '#0f0'; + ctx.stroke(); + ctx.restore(); + + ctx.beginPath(); + ctx.rect(-25, -12.5, 150, 75); + ctx.save(); + ctx.rotate(Math.PI/2); + ctx.scale(25, 50); + ctx.strokeStyle = '#f00'; + ctx.stroke(); + ctx.restore(); + + @assert pixel 0,0 == 0,255,0,255; + @assert pixel 50,0 == 0,255,0,255; + @assert pixel 99,0 == 0,255,0,255; + @assert pixel 0,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 99,25 == 0,255,0,255; + @assert pixel 0,49 == 0,255,0,255; + @assert pixel 50,49 == 0,255,0,255; + @assert pixel 99,49 == 0,255,0,255; + expected: green + +- name: 2d.path.stroke.skew + desc: Strokes lines are skewed by the current transformation matrix + testing: + - 2d.path.transformation + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.save(); + ctx.beginPath(); + ctx.moveTo(49, -50); + ctx.lineTo(201, -50); + ctx.rotate(Math.PI/4); + ctx.scale(1, 283); + ctx.strokeStyle = '#0f0'; + ctx.stroke(); + ctx.restore(); + + ctx.save(); + ctx.beginPath(); + ctx.translate(-150, 0); + ctx.moveTo(49, -50); + ctx.lineTo(199, -50); + ctx.rotate(Math.PI/4); + ctx.scale(1, 142); + ctx.strokeStyle = '#f00'; + ctx.stroke(); + ctx.restore(); + + ctx.save(); + ctx.beginPath(); + ctx.translate(-150, 0); + ctx.moveTo(49, -50); + ctx.lineTo(199, -50); + ctx.rotate(Math.PI/4); + ctx.scale(1, 142); + ctx.strokeStyle = '#f00'; + ctx.stroke(); + ctx.restore(); + + @assert pixel 0,0 == 0,255,0,255; + @assert pixel 50,0 == 0,255,0,255; + @assert pixel 99,0 == 0,255,0,255; + @assert pixel 0,25 == 0,255,0,255; + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 99,25 == 0,255,0,255; + @assert pixel 0,49 == 0,255,0,255; + @assert pixel 50,49 == 0,255,0,255; + @assert pixel 99,49 == 0,255,0,255; + expected: green + +- name: 2d.path.stroke.empty + desc: Empty subpaths are not stroked + testing: + - 2d.path.stroke.empty + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 100; + ctx.lineCap = 'round'; + ctx.lineJoin = 'round'; + + ctx.beginPath(); + ctx.moveTo(40, 25); + ctx.moveTo(60, 25); + ctx.stroke(); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.stroke.prune.line + desc: Zero-length line segments from lineTo are removed before stroking + testing: + - 2d.path.stroke.prune + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 100; + ctx.lineCap = 'round'; + ctx.lineJoin = 'round'; + + ctx.beginPath(); + ctx.moveTo(50, 25); + ctx.lineTo(50, 25); + ctx.stroke(); + + @assert pixel 50,25 == 0,255,0,255; @moz-todo + expected: green + +- name: 2d.path.stroke.prune.closed + desc: Zero-length line segments from closed paths are removed before stroking + testing: + - 2d.path.stroke.prune + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 100; + ctx.lineCap = 'round'; + ctx.lineJoin = 'round'; + + ctx.beginPath(); + ctx.moveTo(50, 25); + ctx.lineTo(50, 25); + ctx.closePath(); + ctx.stroke(); + + @assert pixel 50,25 == 0,255,0,255; @moz-todo + expected: green + +- name: 2d.path.stroke.prune.curve + desc: Zero-length line segments from quadraticCurveTo and bezierCurveTo are removed before stroking + testing: + - 2d.path.stroke.prune + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 100; + ctx.lineCap = 'round'; + ctx.lineJoin = 'round'; + + ctx.beginPath(); + ctx.moveTo(50, 25); + ctx.quadraticCurveTo(50, 25, 50, 25); + ctx.stroke(); + + ctx.beginPath(); + ctx.moveTo(50, 25); + ctx.bezierCurveTo(50, 25, 50, 25, 50, 25); + ctx.stroke(); + + @assert pixel 50,25 == 0,255,0,255; @moz-todo + expected: green + +- name: 2d.path.stroke.prune.arc + desc: Zero-length line segments from arcTo and arc are removed before stroking + testing: + - 2d.path.stroke.prune + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 100; + ctx.lineCap = 'round'; + ctx.lineJoin = 'round'; + + ctx.beginPath(); + ctx.moveTo(50, 25); + ctx.arcTo(50, 25, 150, 25, 10); + ctx.stroke(); + + ctx.beginPath(); + ctx.moveTo(60, 25); + ctx.arc(50, 25, 10, 0, 0, false); + ctx.stroke(); + + @assert pixel 50,25 == 0,255,0,255; @moz-todo + expected: green + +- name: 2d.path.stroke.prune.rect + desc: Zero-length line segments from rect and strokeRect are removed before stroking + testing: + - 2d.path.stroke.prune + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 100; + ctx.lineCap = 'round'; + ctx.lineJoin = 'round'; + + ctx.beginPath(); + ctx.rect(50, 25, 0, 0); + ctx.stroke(); + + ctx.strokeRect(50, 25, 0, 0); + + @assert pixel 50,25 == 0,255,0,255; @moz-todo + expected: green + +- name: 2d.path.stroke.prune.corner + desc: Zero-length line segments are removed before stroking with miters + testing: + - 2d.path.stroke.prune + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 400; + ctx.lineJoin = 'miter'; + ctx.miterLimit = 1.4; + + ctx.beginPath(); + ctx.moveTo(-1000, 200); + ctx.lineTo(-100, 200); + ctx.lineTo(-100, 200); + ctx.lineTo(-100, 200); + ctx.lineTo(-100, 1000); + ctx.stroke(); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + + +- name: 2d.path.transformation.basic + testing: + - 2d.path.transformation + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.translate(-100, 0); + ctx.rect(100, 0, 100, 50); + ctx.translate(0, -100); + ctx.fillStyle = '#0f0'; + ctx.fill(); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.transformation.multiple + # TODO: change this name + desc: Transformations are applied while building paths, not when drawing + testing: + - 2d.path.transformation + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.fillStyle = '#f00'; + ctx.translate(-100, 0); + ctx.rect(0, 0, 100, 50); + ctx.fill(); + ctx.translate(100, 0); + ctx.fill(); + + ctx.beginPath(); + ctx.strokeStyle = '#f00'; + ctx.lineWidth = 50; + ctx.translate(0, -50); + ctx.moveTo(0, 25); + ctx.lineTo(100, 25); + ctx.stroke(); + ctx.translate(0, 50); + ctx.stroke(); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.transformation.changing + desc: Transformations are applied while building paths, not when drawing + testing: + - 2d.path.transformation + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.moveTo(0, 0); + ctx.translate(100, 0); + ctx.lineTo(0, 0); + ctx.translate(0, 50); + ctx.lineTo(0, 0); + ctx.translate(-100, 0); + ctx.lineTo(0, 0); + ctx.translate(1000, 1000); + ctx.rotate(Math.PI/2); + ctx.scale(0.1, 0.1); + ctx.fill(); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + + +- name: 2d.path.clip.empty + testing: + - 2d.path.clip.basic + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.beginPath(); + ctx.clip(); + + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.clip.basic.1 + testing: + - 2d.path.clip.basic + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.beginPath(); + ctx.rect(0, 0, 100, 50); + ctx.clip(); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.clip.basic.2 + testing: + - 2d.path.clip.basic + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.beginPath(); + ctx.rect(-100, 0, 100, 50); + ctx.clip(); + + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.clip.intersect + testing: + - 2d.path.clip.basic + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.beginPath(); + ctx.rect(0, 0, 50, 50); + ctx.clip(); + ctx.beginPath(); + ctx.rect(50, 0, 50, 50) + ctx.clip(); + + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.clip.winding.1 + testing: + - 2d.path.clip.basic + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + ctx.beginPath(); + ctx.moveTo(-10, -10); + ctx.lineTo(110, -10); + ctx.lineTo(110, 60); + ctx.lineTo(-10, 60); + ctx.lineTo(-10, -10); + ctx.lineTo(0, 0); + ctx.lineTo(0, 50); + ctx.lineTo(100, 50); + ctx.lineTo(100, 0); + ctx.clip(); + + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.clip.winding.2 + testing: + - 2d.path.clip.basic + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.beginPath(); + ctx.moveTo(-10, -10); + ctx.lineTo(110, -10); + ctx.lineTo(110, 60); + ctx.lineTo(-10, 60); + ctx.lineTo(-10, -10); + ctx.clip(); + + ctx.beginPath(); + ctx.moveTo(0, 0); + ctx.lineTo(0, 50); + ctx.lineTo(100, 50); + ctx.lineTo(100, 0); + ctx.lineTo(0, 0); + ctx.clip(); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.path.clip.unaffected + testing: + - 2d.path.clip.closed + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.fillStyle = '#0f0'; + + ctx.beginPath(); + ctx.moveTo(0, 0); + ctx.lineTo(0, 50); + ctx.lineTo(100, 50); + ctx.lineTo(100, 0); + ctx.clip(); + + ctx.lineTo(0, 0); + ctx.fill(); + + @assert pixel 50,25 == 0,255,0,255; + expected: green + + + +- name: 2d.path.isPointInPath.basic.1 + desc: isPointInPath() detects whether the point is inside the path + testing: + - 2d.path.isPointInPath + code: | + ctx.rect(0, 0, 20, 20); + @assert ctx.isPointInPath(10, 10) === true; + @assert ctx.isPointInPath(30, 10) === false; + +- name: 2d.path.isPointInPath.basic.2 + desc: isPointInPath() detects whether the point is inside the path + testing: + - 2d.path.isPointInPath + code: | + ctx.rect(20, 0, 20, 20); + @assert ctx.isPointInPath(10, 10) === false; + @assert ctx.isPointInPath(30, 10) === true; + +- name: 2d.path.isPointInPath.edge + desc: isPointInPath() counts points on the path as being inside + testing: + - 2d.path.isPointInPath.edge + code: | + ctx.rect(0, 0, 20, 20); + @assert ctx.isPointInPath(0, 0) === true; + @assert ctx.isPointInPath(10, 0) === true; + @assert ctx.isPointInPath(20, 0) === true; + @assert ctx.isPointInPath(20, 10) === true; + @assert ctx.isPointInPath(20, 20) === true; + @assert ctx.isPointInPath(10, 20) === true; + @assert ctx.isPointInPath(0, 20) === true; + @assert ctx.isPointInPath(0, 10) === true; + @assert ctx.isPointInPath(10, -0.01) === false; + @assert ctx.isPointInPath(10, 20.01) === false; + @assert ctx.isPointInPath(-0.01, 10) === false; + @assert ctx.isPointInPath(20.01, 10) === false; + +- name: 2d.path.isPointInPath.empty + desc: isPointInPath() works when there is no path + testing: + - 2d.path.isPointInPath + code: | + @assert ctx.isPointInPath(0, 0) === false; + +- name: 2d.path.isPointInPath.subpath + desc: isPointInPath() uses the current path, not just the subpath + testing: + - 2d.path.isPointInPath + code: | + ctx.rect(0, 0, 20, 20); + ctx.beginPath(); + ctx.rect(20, 0, 20, 20); + ctx.closePath(); + ctx.rect(40, 0, 20, 20); + @assert ctx.isPointInPath(10, 10) === false; + @assert ctx.isPointInPath(30, 10) === true; + @assert ctx.isPointInPath(50, 10) === true; + +- name: 2d.path.isPointInPath.outside + desc: isPointInPath() works on paths outside the canvas + testing: + - 2d.path.isPointInPath + code: | + ctx.rect(0, -100, 20, 20); + ctx.rect(20, -10, 20, 20); + @assert ctx.isPointInPath(10, -110) === false; + @assert ctx.isPointInPath(10, -90) === true; + @assert ctx.isPointInPath(10, -70) === false; + @assert ctx.isPointInPath(30, -20) === false; + @assert ctx.isPointInPath(30, 0) === true; + @assert ctx.isPointInPath(30, 20) === false; + +- name: 2d.path.isPointInPath.unclosed + desc: isPointInPath() works on unclosed subpaths + testing: + - 2d.path.isPointInPath + code: | + ctx.moveTo(0, 0); + ctx.lineTo(20, 0); + ctx.lineTo(20, 20); + ctx.lineTo(0, 20); + @assert ctx.isPointInPath(10, 10) === true; + @assert ctx.isPointInPath(30, 10) === false; + +- name: 2d.path.isPointInPath.arc + desc: isPointInPath() works on arcs + testing: + - 2d.path.isPointInPath + code: | + ctx.arc(50, 25, 10, 0, Math.PI, false); + @assert ctx.isPointInPath(50, 10) === false; + @assert ctx.isPointInPath(50, 20) === false; + @assert ctx.isPointInPath(50, 30) === true; + @assert ctx.isPointInPath(50, 40) === false; + @assert ctx.isPointInPath(30, 20) === false; + @assert ctx.isPointInPath(70, 20) === false; + @assert ctx.isPointInPath(30, 30) === false; + @assert ctx.isPointInPath(70, 30) === false; + +- name: 2d.path.isPointInPath.bigarc + desc: isPointInPath() works on unclosed arcs larger than 2pi + opera: { bug: 320937 } + testing: + - 2d.path.isPointInPath + code: | + ctx.arc(50, 25, 10, 0, 7, false); + @assert ctx.isPointInPath(50, 10) === false; + @assert ctx.isPointInPath(50, 20) === true; + @assert ctx.isPointInPath(50, 30) === true; + @assert ctx.isPointInPath(50, 40) === false; + @assert ctx.isPointInPath(30, 20) === false; + @assert ctx.isPointInPath(70, 20) === false; + @assert ctx.isPointInPath(30, 30) === false; + @assert ctx.isPointInPath(70, 30) === false; + +- name: 2d.path.isPointInPath.bezier + desc: isPointInPath() works on Bezier curves + testing: + - 2d.path.isPointInPath + code: | + ctx.moveTo(25, 25); + ctx.bezierCurveTo(50, -50, 50, 100, 75, 25); + @assert ctx.isPointInPath(25, 20) === false; + @assert ctx.isPointInPath(25, 30) === false; + @assert ctx.isPointInPath(30, 20) === true; + @assert ctx.isPointInPath(30, 30) === false; + @assert ctx.isPointInPath(40, 2) === false; + @assert ctx.isPointInPath(40, 20) === true; + @assert ctx.isPointInPath(40, 30) === false; + @assert ctx.isPointInPath(40, 47) === false; + @assert ctx.isPointInPath(45, 20) === true; + @assert ctx.isPointInPath(45, 30) === false; + @assert ctx.isPointInPath(55, 20) === false; + @assert ctx.isPointInPath(55, 30) === true; + @assert ctx.isPointInPath(60, 2) === false; + @assert ctx.isPointInPath(60, 20) === false; + @assert ctx.isPointInPath(60, 30) === true; + @assert ctx.isPointInPath(60, 47) === false; + @assert ctx.isPointInPath(70, 20) === false; + @assert ctx.isPointInPath(70, 30) === true; + @assert ctx.isPointInPath(75, 20) === false; + @assert ctx.isPointInPath(75, 30) === false; + +- name: 2d.path.isPointInPath.winding + desc: isPointInPath() uses the non-zero winding number rule + testing: + - 2d.path.isPointInPath + code: | + // Create a square ring, using opposite windings to make a hole in the centre + ctx.moveTo(0, 0); + ctx.lineTo(50, 0); + ctx.lineTo(50, 50); + ctx.lineTo(0, 50); + ctx.lineTo(0, 0); + ctx.lineTo(10, 10); + ctx.lineTo(10, 40); + ctx.lineTo(40, 40); + ctx.lineTo(40, 10); + ctx.lineTo(10, 10); + + @assert ctx.isPointInPath(5, 5) === true; + @assert ctx.isPointInPath(25, 5) === true; + @assert ctx.isPointInPath(45, 5) === true; + @assert ctx.isPointInPath(5, 25) === true; + @assert ctx.isPointInPath(25, 25) === false; + @assert ctx.isPointInPath(45, 25) === true; + @assert ctx.isPointInPath(5, 45) === true; + @assert ctx.isPointInPath(25, 45) === true; + @assert ctx.isPointInPath(45, 45) === true; + +- name: 2d.path.isPointInPath.transform.1 + desc: isPointInPath() handles transformations correctly + testing: + - 2d.path.isPointInPath + code: | + ctx.translate(50, 0); + ctx.rect(0, 0, 20, 20); + @assert ctx.isPointInPath(-40, 10) === false; + @assert ctx.isPointInPath(10, 10) === false; + @assert ctx.isPointInPath(49, 10) === false; + @assert ctx.isPointInPath(51, 10) === true; + @assert ctx.isPointInPath(69, 10) === true; + @assert ctx.isPointInPath(71, 10) === false; + +- name: 2d.path.isPointInPath.transform.2 + desc: isPointInPath() handles transformations correctly + testing: + - 2d.path.isPointInPath + code: | + ctx.rect(50, 0, 20, 20); + ctx.translate(50, 0); + @assert ctx.isPointInPath(-40, 10) === false; + @assert ctx.isPointInPath(10, 10) === false; + @assert ctx.isPointInPath(49, 10) === false; + @assert ctx.isPointInPath(51, 10) === true; + @assert ctx.isPointInPath(69, 10) === true; + @assert ctx.isPointInPath(71, 10) === false; + +- name: 2d.path.isPointInPath.transform.3 + desc: isPointInPath() handles transformations correctly + testing: + - 2d.path.isPointInPath + code: | + ctx.scale(-1, 1); + ctx.rect(-70, 0, 20, 20); + @assert ctx.isPointInPath(-40, 10) === false; + @assert ctx.isPointInPath(10, 10) === false; + @assert ctx.isPointInPath(49, 10) === false; + @assert ctx.isPointInPath(51, 10) === true; + @assert ctx.isPointInPath(69, 10) === true; + @assert ctx.isPointInPath(71, 10) === false; + +- name: 2d.path.isPointInPath.transform.4 + desc: isPointInPath() handles transformations correctly + testing: + - 2d.path.isPointInPath + code: | + ctx.translate(50, 0); + ctx.rect(50, 0, 20, 20); + ctx.translate(0, 50); + @assert ctx.isPointInPath(60, 10) === false; + @assert ctx.isPointInPath(110, 10) === true; + @assert ctx.isPointInPath(110, 60) === false; + +- name: 2d.path.isPointInPath.nonfinite + desc: isPointInPath() returns false for non-finite arguments + testing: + - 2d.path.isPointInPath.nonfinite + code: | + ctx.rect(-100, -50, 200, 100); + @assert ctx.isPointInPath(Infinity, 0) === false; + @assert ctx.isPointInPath(-Infinity, 0) === false; + @assert ctx.isPointInPath(NaN, 0) === false; + @assert ctx.isPointInPath(0, Infinity) === false; + @assert ctx.isPointInPath(0, -Infinity) === false; + @assert ctx.isPointInPath(0, NaN) === false; + @assert ctx.isPointInPath(NaN, NaN) === false; + + +- name: 2d.drawImage.3arg + testing: + - 2d.drawImage.defaultsource + - 2d.drawImage.defaultdest + images: + - red.png + - green.png + code: | + ctx.drawImage(document.getElementById('green.png'), 0, 0); + ctx.drawImage(document.getElementById('red.png'), -100, 0); + ctx.drawImage(document.getElementById('red.png'), 100, 0); + ctx.drawImage(document.getElementById('red.png'), 0, -50); + ctx.drawImage(document.getElementById('red.png'), 0, 50); + + @assert pixel 0,0 ==~ 0,255,0,255; + @assert pixel 99,0 ==~ 0,255,0,255; + @assert pixel 0,49 ==~ 0,255,0,255; + @assert pixel 99,49 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.5arg + testing: + - 2d.drawImage.defaultsource + images: + - red.png + - green.png + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.drawImage(document.getElementById('green.png'), 50, 0, 50, 50); + ctx.drawImage(document.getElementById('red.png'), 0, 0, 50, 50); + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 50, 50); + + @assert pixel 0,0 ==~ 0,255,0,255; + @assert pixel 99,0 ==~ 0,255,0,255; + @assert pixel 0,49 ==~ 0,255,0,255; + @assert pixel 99,49 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.9arg.basic + testing: + - 2d.drawImage.paint + images: + - green.png + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.drawImage(document.getElementById('green.png'), 0, 0, 100, 50, 0, 0, 100, 50); + @assert pixel 0,0 ==~ 0,255,0,255; + @assert pixel 99,0 ==~ 0,255,0,255; + @assert pixel 0,49 ==~ 0,255,0,255; + @assert pixel 99,49 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.9arg.sourcepos + testing: + - 2d.drawImage.paint + images: + - rgrg-256x256.png + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.drawImage(document.getElementById('rgrg-256x256.png'), 140, 20, 100, 50, 0, 0, 100, 50); + @assert pixel 0,0 ==~ 0,255,0,255; + @assert pixel 99,0 ==~ 0,255,0,255; + @assert pixel 0,49 ==~ 0,255,0,255; + @assert pixel 99,49 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.9arg.sourcesize + testing: + - 2d.drawImage.paint + images: + - rgrg-256x256.png + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.drawImage(document.getElementById('rgrg-256x256.png'), 0, 0, 256, 256, 0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 51, 26); + ctx.fillRect(49, 24, 51, 26); + @assert pixel 0,0 ==~ 0,255,0,255; + @assert pixel 99,0 ==~ 0,255,0,255; + @assert pixel 0,49 ==~ 0,255,0,255; + @assert pixel 99,49 ==~ 0,255,0,255; + @assert pixel 20,20 ==~ 0,255,0,255; + @assert pixel 80,20 ==~ 0,255,0,255; + @assert pixel 20,30 ==~ 0,255,0,255; + @assert pixel 80,30 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.9arg.destpos + testing: + - 2d.drawImage.paint + images: + - red.png + - green.png + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.drawImage(document.getElementById('green.png'), 0, 0, 100, 50, 0, 0, 100, 50); + ctx.drawImage(document.getElementById('red.png'), 0, 0, 100, 50, -100, 0, 100, 50); + ctx.drawImage(document.getElementById('red.png'), 0, 0, 100, 50, 100, 0, 100, 50); + ctx.drawImage(document.getElementById('red.png'), 0, 0, 100, 50, 0, -50, 100, 50); + ctx.drawImage(document.getElementById('red.png'), 0, 0, 100, 50, 0, 50, 100, 50); + @assert pixel 0,0 ==~ 0,255,0,255; + @assert pixel 99,0 ==~ 0,255,0,255; + @assert pixel 0,49 ==~ 0,255,0,255; + @assert pixel 99,49 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.9arg.destsize + testing: + - 2d.drawImage.paint + images: + - red.png + - green.png + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.drawImage(document.getElementById('green.png'), 1, 1, 1, 1, 0, 0, 100, 50); + ctx.drawImage(document.getElementById('red.png'), 0, 0, 100, 50, -50, 0, 50, 50); + ctx.drawImage(document.getElementById('red.png'), 0, 0, 100, 50, 100, 0, 50, 50); + ctx.drawImage(document.getElementById('red.png'), 0, 0, 100, 50, 0, -25, 100, 25); + ctx.drawImage(document.getElementById('red.png'), 0, 0, 100, 50, 0, 50, 100, 25); + @assert pixel 0,0 ==~ 0,255,0,255; + @assert pixel 99,0 ==~ 0,255,0,255; + @assert pixel 0,49 ==~ 0,255,0,255; + @assert pixel 99,49 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.canvas + testing: + - 2d.drawImage.paint + code: | + var canvas2 = document.createElement('canvas'); + canvas2.width = 100; + canvas2.height = 50; + var ctx2 = canvas2.getContext('2d'); + ctx2.fillStyle = '#0f0'; + ctx2.fillRect(0, 0, 100, 50); + + ctx.fillStyle = '#f00'; + ctx.drawImage(canvas2, 0, 0); + + @assert pixel 0,0 ==~ 0,255,0,255; + @assert pixel 99,0 ==~ 0,255,0,255; + @assert pixel 0,49 ==~ 0,255,0,255; + @assert pixel 99,49 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.self.1 + testing: + - 2d.drawImage.self + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 50, 50); + ctx.fillStyle = '#f00'; + ctx.fillRect(50, 0, 50, 50); + ctx.drawImage(canvas, 50, 0); + + @assert pixel 0,0 ==~ 0,255,0,255; + @assert pixel 99,0 ==~ 0,255,0,255; + @assert pixel 0,49 ==~ 0,255,0,255; + @assert pixel 99,49 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.self.2 + testing: + - 2d.drawImage.self + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 1, 100, 49); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 1); + ctx.drawImage(canvas, 0, 1); + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 2); + + @assert pixel 0,0 ==~ 0,255,0,255; + @assert pixel 99,0 ==~ 0,255,0,255; + @assert pixel 0,49 ==~ 0,255,0,255; + @assert pixel 99,49 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.null + testing: + - 2d.drawImage.IDL + code: | + @assert throws TypeError ctx.drawImage(null, 0, 0); + +- name: 2d.drawImage.wrongtype + desc: Incorrect image types in drawImage do not match any defined overloads, so WebIDL throws a TypeError + notes: *bindings + testing: + - 2d.drawImage.IDL + code: | + @assert throws TypeError ctx.drawImage(undefined, 0, 0); + @assert throws TypeError ctx.drawImage(0, 0, 0); + @assert throws TypeError ctx.drawImage("", 0, 0); + @assert throws TypeError ctx.drawImage(document.createElement('p'), 0, 0); + +- name: 2d.drawImage.floatsource + testing: + - 2d.drawImage.paint + images: + - green.png + code: | + ctx.drawImage(document.getElementById('green.png'), 10.1, 10.1, 0.1, 0.1, 0, 0, 100, 50); + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.zerosource + desc: drawImage with zero-sized source rectangle throws INDEX_SIZE_ERR + testing: + - 2d.drawImage.zerosource + images: + - red.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + @assert throws INDEX_SIZE_ERR ctx.drawImage(document.getElementById('red.png'), 10, 10, 0, 1, 0, 0, 100, 50); + @assert throws INDEX_SIZE_ERR ctx.drawImage(document.getElementById('red.png'), 10, 10, 1, 0, 0, 0, 100, 50); + @assert throws INDEX_SIZE_ERR ctx.drawImage(document.getElementById('red.png'), 10, 10, 0, 0, 0, 0, 100, 50); + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.zerosource.image + desc: drawImage with zero-sized source rectangle from image throws INDEX_SIZE_ERR + testing: + - 2d.drawImage.zerosource + images: + - red-zerowidth.svg + - red-zeroheight.svg + - red-zerosize.svg + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + @assert throws INDEX_SIZE_ERR ctx.drawImage(document.getElementById('red-zerowidth.svg'), 0, 0, 100, 50); + @assert throws INDEX_SIZE_ERR ctx.drawImage(document.getElementById('red-zeroheight.svg'), 0, 0, 100, 50); + @assert throws INDEX_SIZE_ERR ctx.drawImage(document.getElementById('red-zerosize.svg'), 0, 0, 100, 50); + @assert pixel 50,25 == 0,255,0,255; + expected: green + +- name: 2d.drawImage.negativesource + desc: Negative source width/height represents the correct rectangle + testing: + - 2d.drawImage.direction + mozilla: { throws } + images: + - ggrr-256x256.png + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.drawImage(document.getElementById('ggrr-256x256.png'), 100, 78, -100, 50, 0, 0, 50, 50); + ctx.drawImage(document.getElementById('ggrr-256x256.png'), 100, 128, -100, -50, 50, 0, 50, 50); + @assert pixel 1,1 ==~ 0,255,0,255; + @assert pixel 1,48 ==~ 0,255,0,255; + @assert pixel 98,1 ==~ 0,255,0,255; + @assert pixel 98,48 ==~ 0,255,0,255; + @assert pixel 48,1 ==~ 0,255,0,255; + @assert pixel 48,48 ==~ 0,255,0,255; + @assert pixel 51,1 ==~ 0,255,0,255; + @assert pixel 51,48 ==~ 0,255,0,255; + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.negativedest + desc: Negative destination width/height represents the correct rectangle + testing: + - 2d.drawImage.direction + mozilla: { throws } + images: + - ggrr-256x256.png + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.drawImage(document.getElementById('ggrr-256x256.png'), 100, 78, 50, 50, 0, 50, 50, -50); + ctx.drawImage(document.getElementById('ggrr-256x256.png'), 100, 128, 50, -50, 100, 50, -50, -50); + @assert pixel 1,1 ==~ 0,255,0,255; + @assert pixel 1,48 ==~ 0,255,0,255; + @assert pixel 98,1 ==~ 0,255,0,255; + @assert pixel 98,48 ==~ 0,255,0,255; + @assert pixel 48,1 ==~ 0,255,0,255; + @assert pixel 48,48 ==~ 0,255,0,255; + @assert pixel 51,1 ==~ 0,255,0,255; + @assert pixel 51,48 ==~ 0,255,0,255; + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.negativedir + desc: Negative dimensions do not affect the direction of the image + testing: + - 2d.drawImage.direction + mozilla: { throws } + images: + - ggrr-256x256.png + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.drawImage(document.getElementById('ggrr-256x256.png'), 0, 178, 50, -100, 0, 0, 50, 100); + ctx.drawImage(document.getElementById('ggrr-256x256.png'), 0, 78, 50, 100, 50, 100, 50, -100); + @assert pixel 1,1 ==~ 0,255,0,255; + @assert pixel 1,48 ==~ 0,255,0,255; + @assert pixel 98,1 ==~ 0,255,0,255; + @assert pixel 98,48 ==~ 0,255,0,255; + @assert pixel 48,1 ==~ 0,255,0,255; + @assert pixel 48,48 ==~ 0,255,0,255; + @assert pixel 51,1 ==~ 0,255,0,255; + @assert pixel 51,48 ==~ 0,255,0,255; + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.outsidesource + DISABLED: fix this to match the current spec (transparent black outside source) + testing: + - 2d.drawImage.outsidesource + mozilla: { throws } + images: + - green.png + - red.png + code: | + ctx.drawImage(document.getElementById('green.png'), 10.5, 10.5, 89.5, 39.5, 0, 0, 100, 50); + ctx.drawImage(document.getElementById('green.png'), 5.5, 5.5, -5.5, -5.5, 0, 0, 100, 50); + ctx.drawImage(document.getElementById('green.png'), 100, 50, -5, -5, 0, 0, 100, 50); + @assert throws INDEX_SIZE_ERR ctx.drawImage(document.getElementById('red.png'), -0.001, 0, 100, 50, 0, 0, 100, 50); + @assert throws INDEX_SIZE_ERR ctx.drawImage(document.getElementById('red.png'), 0, -0.001, 100, 50, 0, 0, 100, 50); + @assert throws INDEX_SIZE_ERR ctx.drawImage(document.getElementById('red.png'), 0, 0, 100.001, 50, 0, 0, 100, 50); + @assert throws INDEX_SIZE_ERR ctx.drawImage(document.getElementById('red.png'), 0, 0, 100, 50.001, 0, 0, 100, 50); + @assert throws INDEX_SIZE_ERR ctx.drawImage(document.getElementById('red.png'), 50, 0, 50.001, 50, 0, 0, 100, 50); @moz-todo + @assert throws INDEX_SIZE_ERR ctx.drawImage(document.getElementById('red.png'), 0, 0, -5, 5, 0, 0, 100, 50); + @assert throws INDEX_SIZE_ERR ctx.drawImage(document.getElementById('red.png'), 0, 0, 5, -5, 0, 0, 100, 50); + @assert throws INDEX_SIZE_ERR ctx.drawImage(document.getElementById('red.png'), 110, 60, -20, -20, 0, 0, 100, 50); + @assert pixel 50,25 ==~ 0,255,0,255; @moz-todo + expected: green + +- name: 2d.drawImage.incomplete.nosrc + testing: + - 2d.drawImage.incomplete.image + mozilla: { throws } + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + var img = new Image(); + ctx.drawImage(img, 0, 0); + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.incomplete.immediate + testing: + - 2d.drawImage.incomplete.image + images: + - red.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + var img = new Image(); + img.src = '../images/red.png'; + // This triggers the "update the image data" algorithm. + // The image will not go to the "completely available" state + // until a fetch task in the networking task source is processed, + // so the image must not be fully decodable yet: + ctx.drawImage(img, 0, 0); + @assert pixel 50,25 ==~ 0,255,0,255; @moz-todo + expected: green + +- name: 2d.drawImage.incomplete.reload + testing: + - 2d.drawImage.incomplete.image + images: + - yellow.png + - red.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + var img = document.getElementById('yellow.png'); + img.src = '../images/red.png'; + // This triggers the "update the image data" algorithm, + // and resets the image to the "unavailable" state. + // The image will not go to the "completely available" state + // until a fetch task in the networking task source is processed, + // so the image must not be fully decodable yet: + ctx.drawImage(img, 0, 0); + @assert pixel 50,25 ==~ 0,255,0,255; @moz-todo + expected: green + +- name: 2d.drawImage.incomplete.emptysrc + testing: + - 2d.drawImage.incomplete.image + images: + - red.png + mozilla: { throws } + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + var img = document.getElementById('red.png'); + img.src = ""; + ctx.drawImage(img, 0, 0); + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.incomplete.removedsrc + testing: + - 2d.drawImage.incomplete.image + images: + - red.png + mozilla: { throws } + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + var img = document.getElementById('red.png'); + img.removeAttribute('src'); + ctx.drawImage(img, 0, 0); + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.broken + testing: + - 2d.drawImage.incomplete.image + images: + - broken.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + var img = document.getElementById('broken.png'); + ctx.drawImage(img, 0, 0); + @assert pixel 50,25 ==~ 0,255,0,255; @moz-todo + expected: green + +- name: 2d.drawImage.zerocanvas + testing: + - 2d.drawImage.zerocanvas + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + + var canvas2 = document.createElement('canvas'); + canvas2.width = 0; + canvas2.height = 10; + @assert throws INVALID_STATE_ERR ctx.drawImage(canvas2, 0, 0); + + canvas2.width = 10; + canvas2.height = 0; + @assert throws INVALID_STATE_ERR ctx.drawImage(canvas2, 0, 0); + + canvas2.width = 0; + canvas2.height = 0; + @assert throws INVALID_STATE_ERR ctx.drawImage(canvas2, 0, 0); + + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.svg + desc: drawImage() of an SVG image + testing: + - 2d.drawImage.svg + images: + - green.svg + code: | + ctx.drawImage(document.getElementById('green.svg'), 0, 0); + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.animated.gif + desc: drawImage() of an animated GIF draws the first frame + testing: + - 2d.drawImage.animated.image + images: + - anim-gr.gif + code: | + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.drawImage(document.getElementById('anim-gr.gif'), 0, 0); + @assert pixel 50,25 ==~ 0,255,0,255; + }), 500); + expected: green + +- name: 2d.drawImage.animated.apng + desc: drawImage() of an APNG with no poster frame draws the first frame + testing: + - 2d.drawImage.animated.image + images: + - anim-gr.png + code: | + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.drawImage(document.getElementById('anim-gr.png'), 0, 0); + @assert pixel 50,25 ==~ 0,255,0,255; + }), 500); + expected: green + +- name: 2d.drawImage.animated.poster + desc: drawImage() of an APNG draws the poster frame + testing: + - 2d.drawImage.animated.image + images: + - anim-poster-gr.png + code: | + ctx.drawImage(document.getElementById('anim-poster-gr.png'), 0, 0); + @assert pixel 50,25 ==~ 0,255,0,255; @moz-todo + expected: green + +- name: 2d.drawImage.path + testing: + - 2d.drawImage.unaffect + images: + - red.png + code: | + ctx.fillStyle = '#0f0'; + ctx.rect(0, 0, 100, 50); + ctx.drawImage(document.getElementById('red.png'), 0, 0); + ctx.fill(); + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.transform + testing: + - 2d.drawImage.subject + images: + - red.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.translate(100, 0); + ctx.drawImage(document.getElementById('red.png'), 0, 0); + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +# TODO: drawImage shadows + +- name: 2d.drawImage.alpha + testing: + - 2d.drawImage.subject + images: + - red.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.globalAlpha = 0; + ctx.drawImage(document.getElementById('red.png'), 0, 0); + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.clip + testing: + - 2d.drawImage.subject + images: + - red.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.rect(-10, -10, 1, 1); + ctx.clip(); + ctx.drawImage(document.getElementById('red.png'), 0, 0); + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.composite + testing: + - 2d.drawImage.subject + images: + - red.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.globalCompositeOperation = 'destination-over'; + ctx.drawImage(document.getElementById('red.png'), 0, 0); + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.nowrap + desc: Stretched images do not get pixels wrapping around the edges + images: + - redtransparent.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.drawImage(document.getElementById('redtransparent.png'), -1950, 0, 2000, 50); + @assert pixel 45,25 ==~ 0,255,0,255; + @assert pixel 50,25 ==~ 0,255,0,255; + @assert pixel 55,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.drawImage.nonfinite + desc: drawImage() with Infinity/NaN is ignored + testing: + - 2d.nonfinite + images: + - red.png + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + var red = document.getElementById('red.png'); + @nonfinite ctx.drawImage(, <0 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>); + @nonfinite ctx.drawImage(, <0 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <100 Infinity -Infinity NaN>, <50 Infinity -Infinity NaN>); + @nonfinite ctx.drawImage(, <0 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <100 Infinity -Infinity NaN>, <50 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <0 Infinity -Infinity NaN>, <100 Infinity -Infinity NaN>, <50 Infinity -Infinity NaN>); + @assert pixel 50,25 == 0,255,0,255; + expected: green + + + +- name: 2d.imageData.create2.basic + desc: createImageData(sw, sh) exists and returns something + testing: + - 2d.imageData.create2.object + code: | + @assert ctx.createImageData(1, 1) !== null; + +- name: 2d.imageData.create1.basic + desc: createImageData(imgdata) exists and returns something + testing: + - 2d.imageData.create1.object + code: | + @assert ctx.createImageData(ctx.createImageData(1, 1)) !== null; + +- name: 2d.imageData.create2.type + desc: createImageData(sw, sh) returns an ImageData object containing a Uint8ClampedArray object + testing: + - 2d.imageData.create2.object + code: | + @assert window.ImageData !== undefined; + @assert window.Uint8ClampedArray !== undefined; + window.ImageData.prototype.thisImplementsImageData = true; + window.Uint8ClampedArray.prototype.thisImplementsUint8ClampedArray = true; + var imgdata = ctx.createImageData(1, 1); + @assert imgdata.thisImplementsImageData; + @assert imgdata.data.thisImplementsUint8ClampedArray; + +- name: 2d.imageData.create1.type + desc: createImageData(imgdata) returns an ImageData object containing a Uint8ClampedArray object + testing: + - 2d.imageData.create1.object + code: | + @assert window.ImageData !== undefined; + @assert window.Uint8ClampedArray !== undefined; + window.ImageData.prototype.thisImplementsImageData = true; + window.Uint8ClampedArray.prototype.thisImplementsUint8ClampedArray = true; + var imgdata = ctx.createImageData(ctx.createImageData(1, 1)); + @assert imgdata.thisImplementsImageData; + @assert imgdata.data.thisImplementsUint8ClampedArray; + +- name: 2d.imageData.create2.this + desc: createImageData(sw, sh) should throw when called with the wrong |this| + notes: *bindings + testing: + - 2d.imageData.create2.object + code: | + @assert throws TypeError CanvasRenderingContext2D.prototype.createImageData.call(null, 1, 1); @moz-todo + @assert throws TypeError CanvasRenderingContext2D.prototype.createImageData.call(undefined, 1, 1); @moz-todo + @assert throws TypeError CanvasRenderingContext2D.prototype.createImageData.call({}, 1, 1); @moz-todo + +- name: 2d.imageData.create1.this + desc: createImageData(imgdata) should throw when called with the wrong |this| + notes: *bindings + testing: + - 2d.imageData.create2.object + code: | + var imgdata = ctx.createImageData(1, 1); + @assert throws TypeError CanvasRenderingContext2D.prototype.createImageData.call(null, imgdata); @moz-todo + @assert throws TypeError CanvasRenderingContext2D.prototype.createImageData.call(undefined, imgdata); @moz-todo + @assert throws TypeError CanvasRenderingContext2D.prototype.createImageData.call({}, imgdata); @moz-todo + +- name: 2d.imageData.create2.initial + desc: createImageData(sw, sh) returns transparent black data of the right size + testing: + - 2d.imageData.create2.size + - 2d.imageData.create.initial + - 2d.imageData.initial + code: | + var imgdata = ctx.createImageData(10, 20); + @assert imgdata.data.length === imgdata.width*imgdata.height*4; + @assert imgdata.width < imgdata.height; + @assert imgdata.width > 0; + var isTransparentBlack = true; + for (var i = 0; i < imgdata.data.length; ++i) + if (imgdata.data[i] !== 0) + isTransparentBlack = false; + @assert isTransparentBlack; + +- name: 2d.imageData.create1.initial + desc: createImageData(imgdata) returns transparent black data of the right size + testing: + - 2d.imageData.create1.size + - 2d.imageData.create.initial + - 2d.imageData.initial + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + var imgdata1 = ctx.getImageData(0, 0, 10, 20); + var imgdata2 = ctx.createImageData(imgdata1); + @assert imgdata2.data.length === imgdata1.data.length; + @assert imgdata2.width === imgdata1.width; + @assert imgdata2.height === imgdata1.height; + var isTransparentBlack = true; + for (var i = 0; i < imgdata2.data.length; ++i) + if (imgdata2.data[i] !== 0) + isTransparentBlack = false; + @assert isTransparentBlack; + +- name: 2d.imageData.create2.large + desc: createImageData(sw, sh) works for sizes much larger than the canvas + testing: + - 2d.imageData.create2.size + code: | + var imgdata = ctx.createImageData(1000, 2000); + @assert imgdata.data.length === imgdata.width*imgdata.height*4; + @assert imgdata.width < imgdata.height; + @assert imgdata.width > 0; + var isTransparentBlack = true; + for (var i = 0; i < imgdata.data.length; i += 7813) // check ~1024 points (assuming normal scaling) + if (imgdata.data[i] !== 0) + isTransparentBlack = false; + @assert isTransparentBlack; + +- name: 2d.imageData.create2.tiny + desc: createImageData(sw, sh) works for sizes smaller than one pixel + testing: + - 2d.imageData.create2.size + - 2d.imageData.one + code: | + var imgdata = ctx.createImageData(0.0001, 0.0001); + @assert imgdata.data.length === imgdata.width*imgdata.height*4; + @assert imgdata.width === 1; + @assert imgdata.height === 1; + var isTransparentBlack = true; + for (var i = 0; i < imgdata.data.length; ++i) + if (imgdata.data[i] !== 0) + isTransparentBlack = false; + @assert isTransparentBlack; + +- name: 2d.imageData.create2.negative + desc: createImageData(sw, sh) takes the absolute magnitude of the size arguments + testing: + - 2d.imageData.create2.size + code: | + var imgdata1 = ctx.createImageData(10, 20); + var imgdata2 = ctx.createImageData(-10, 20); + var imgdata3 = ctx.createImageData(10, -20); + var imgdata4 = ctx.createImageData(-10, -20); + @assert imgdata1.data.length === imgdata2.data.length; + @assert imgdata2.data.length === imgdata3.data.length; + @assert imgdata3.data.length === imgdata4.data.length; + +- name: 2d.imageData.create2.zero + desc: createImageData(sw, sh) throws INDEX_SIZE_ERR if size is zero + testing: + - 2d.imageData.getcreate.zero + code: | + @assert throws INDEX_SIZE_ERR ctx.createImageData(10, 0); + @assert throws INDEX_SIZE_ERR ctx.createImageData(0, 10); + @assert throws INDEX_SIZE_ERR ctx.createImageData(0, 0); + +- name: 2d.imageData.create2.nonfinite + desc: createImageData() throws TypeError if arguments are not finite + notes: *bindings + testing: + - 2d.imageData.getcreate.nonfinite + code: | + @nonfinite @assert throws TypeError ctx.createImageData(<10 Infinity -Infinity NaN>, <10 Infinity -Infinity NaN>); + var posinfobj = { valueOf: function() { return Infinity; } }, + neginfobj = { valueOf: function() { return -Infinity; } }, + nanobj = { valueOf: function() { return -Infinity; } }; + @nonfinite @assert throws TypeError ctx.createImageData(<10 posinfobj neginfobj nanobj>, <10 posinfobj neginfobj nanobj>); + +- name: 2d.imageData.create1.zero + desc: createImageData(null) throws TypeError + testing: + - 2d.imageData.create.null + code: | + @assert throws TypeError ctx.createImageData(null); + +- name: 2d.imageData.create2.round + desc: createImageData(w, h) is rounded the same as getImageData(0, 0, w, h) + testing: + - 2d.imageData.createround + code: | + var imgdata1 = ctx.createImageData(10.01, 10.99); + var imgdata2 = ctx.getImageData(0, 0, 10.01, 10.99); + @assert imgdata1.width === imgdata2.width; + @assert imgdata1.height === imgdata2.height; + +- name: 2d.imageData.get.basic + desc: getImageData() exists and returns something + testing: + - 2d.imageData.get.basic + code: | + @assert ctx.getImageData(0, 0, 100, 50) !== null; + +- name: 2d.imageData.get.type + desc: getImageData() returns an ImageData object containing a Uint8ClampedArray object + testing: + - 2d.imageData.get.object + code: | + @assert window.ImageData !== undefined; + @assert window.Uint8ClampedArray !== undefined; + window.ImageData.prototype.thisImplementsImageData = true; + window.Uint8ClampedArray.prototype.thisImplementsUint8ClampedArray = true; + var imgdata = ctx.getImageData(0, 0, 1, 1); + @assert imgdata.thisImplementsImageData; + @assert imgdata.data.thisImplementsUint8ClampedArray; + +- name: 2d.imageData.get.zero + desc: getImageData() throws INDEX_SIZE_ERR if size is zero + testing: + - 2d.imageData.getcreate.zero + code: | + @assert throws INDEX_SIZE_ERR ctx.getImageData(1, 1, 10, 0); + @assert throws INDEX_SIZE_ERR ctx.getImageData(1, 1, 0, 10); + @assert throws INDEX_SIZE_ERR ctx.getImageData(1, 1, 0, 0); + +- name: 2d.imageData.get.nonfinite + desc: getImageData() throws TypeError if arguments are not finite + notes: *bindings + testing: + - 2d.imageData.getcreate.nonfinite + code: | + @nonfinite @assert throws TypeError ctx.getImageData(<10 Infinity -Infinity NaN>, <10 Infinity -Infinity NaN>, <10 Infinity -Infinity NaN>, <10 Infinity -Infinity NaN>); + var posinfobj = { valueOf: function() { return Infinity; } }, + neginfobj = { valueOf: function() { return -Infinity; } }, + nanobj = { valueOf: function() { return -Infinity; } }; + @nonfinite @assert throws TypeError ctx.getImageData(<10 posinfobj neginfobj nanobj>, <10 posinfobj neginfobj nanobj>, <10 posinfobj neginfobj nanobj>, <10 posinfobj neginfobj nanobj>); + +- name: 2d.imageData.get.source.outside + desc: getImageData() returns transparent black outside the canvas + testing: + - 2d.imageData.get.basic + - 2d.imageData.get.outside + code: | + ctx.fillStyle = '#08f'; + ctx.fillRect(0, 0, 100, 50); + + var imgdata1 = ctx.getImageData(-10, 5, 1, 1); + @assert imgdata1.data[0] === 0; + @assert imgdata1.data[1] === 0; + @assert imgdata1.data[2] === 0; + @assert imgdata1.data[3] === 0; + + var imgdata2 = ctx.getImageData(10, -5, 1, 1); + @assert imgdata2.data[0] === 0; + @assert imgdata2.data[1] === 0; + @assert imgdata2.data[2] === 0; + @assert imgdata2.data[3] === 0; + + var imgdata3 = ctx.getImageData(200, 5, 1, 1); + @assert imgdata3.data[0] === 0; + @assert imgdata3.data[1] === 0; + @assert imgdata3.data[2] === 0; + @assert imgdata3.data[3] === 0; + + var imgdata4 = ctx.getImageData(10, 60, 1, 1); + @assert imgdata4.data[0] === 0; + @assert imgdata4.data[1] === 0; + @assert imgdata4.data[2] === 0; + @assert imgdata4.data[3] === 0; + + var imgdata5 = ctx.getImageData(100, 10, 1, 1); + @assert imgdata5.data[0] === 0; + @assert imgdata5.data[1] === 0; + @assert imgdata5.data[2] === 0; + @assert imgdata5.data[3] === 0; + + var imgdata6 = ctx.getImageData(0, 10, 1, 1); + @assert imgdata6.data[0] === 0; + @assert imgdata6.data[1] === 136; + @assert imgdata6.data[2] === 255; + @assert imgdata6.data[3] === 255; + + var imgdata7 = ctx.getImageData(-10, 10, 20, 20); + @assert imgdata7.data[ 0*4+0] === 0; + @assert imgdata7.data[ 0*4+1] === 0; + @assert imgdata7.data[ 0*4+2] === 0; + @assert imgdata7.data[ 0*4+3] === 0; + @assert imgdata7.data[ 9*4+0] === 0; + @assert imgdata7.data[ 9*4+1] === 0; + @assert imgdata7.data[ 9*4+2] === 0; + @assert imgdata7.data[ 9*4+3] === 0; + @assert imgdata7.data[10*4+0] === 0; + @assert imgdata7.data[10*4+1] === 136; + @assert imgdata7.data[10*4+2] === 255; + @assert imgdata7.data[10*4+3] === 255; + @assert imgdata7.data[19*4+0] === 0; + @assert imgdata7.data[19*4+1] === 136; + @assert imgdata7.data[19*4+2] === 255; + @assert imgdata7.data[19*4+3] === 255; + @assert imgdata7.data[20*4+0] === 0; + @assert imgdata7.data[20*4+1] === 0; + @assert imgdata7.data[20*4+2] === 0; + @assert imgdata7.data[20*4+3] === 0; + +- name: 2d.imageData.get.source.negative + desc: getImageData() works with negative width and height, and returns top-to-bottom left-to-right + testing: + - 2d.imageData.get.basic + - 2d.pixelarray.order + code: | + ctx.fillStyle = '#000'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#fff'; + ctx.fillRect(20, 10, 60, 10); + + var imgdata1 = ctx.getImageData(85, 25, -10, -10); + @assert imgdata1.data[0] === 255; + @assert imgdata1.data[1] === 255; + @assert imgdata1.data[2] === 255; + @assert imgdata1.data[3] === 255; + @assert imgdata1.data[imgdata1.data.length-4+0] === 0; + @assert imgdata1.data[imgdata1.data.length-4+1] === 0; + @assert imgdata1.data[imgdata1.data.length-4+2] === 0; + @assert imgdata1.data[imgdata1.data.length-4+3] === 255; + + var imgdata2 = ctx.getImageData(0, 0, -1, -1); + @assert imgdata2.data[0] === 0; + @assert imgdata2.data[1] === 0; + @assert imgdata2.data[2] === 0; + @assert imgdata2.data[3] === 0; + +- name: 2d.imageData.get.source.size + desc: getImageData() returns bigger ImageData for bigger source rectangle + testing: + - 2d.imageData.get.basic + code: | + var imgdata1 = ctx.getImageData(0, 0, 10, 10); + var imgdata2 = ctx.getImageData(0, 0, 20, 20); + @assert imgdata2.width > imgdata1.width; + @assert imgdata2.height > imgdata1.height; + +- name: 2d.imageData.get.tiny + desc: getImageData() works for sizes smaller than one pixel + testing: + - 2d.imageData.one + code: | + var imgdata = ctx.getImageData(0, 0, 0.0001, 0.0001); + @assert imgdata.data.length === imgdata.width*imgdata.height*4; + @assert imgdata.width === 1; + @assert imgdata.height === 1; + +- name: 2d.imageData.get.nonpremul + desc: getImageData() returns non-premultiplied colours + testing: + - 2d.imageData.get.premul + code: | + ctx.fillStyle = 'rgba(255, 255, 255, 0.5)'; + ctx.fillRect(0, 0, 100, 50); + var imgdata = ctx.getImageData(10, 10, 10, 10); + @assert imgdata.data[0] > 200; + @assert imgdata.data[1] > 200; + @assert imgdata.data[2] > 200; + @assert imgdata.data[3] > 100; + @assert imgdata.data[3] < 200; + +- name: 2d.imageData.get.range + desc: getImageData() returns values in the range [0, 255] + testing: + - 2d.pixelarray.range + - 2d.pixelarray.retrieve + code: | + ctx.fillStyle = '#000'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#fff'; + ctx.fillRect(20, 10, 60, 10); + var imgdata1 = ctx.getImageData(10, 5, 1, 1); + @assert imgdata1.data[0] === 0; + var imgdata2 = ctx.getImageData(30, 15, 1, 1); + @assert imgdata2.data[0] === 255; + +- name: 2d.imageData.get.clamp + desc: getImageData() clamps colours to the range [0, 255] + testing: + - 2d.pixelarray.range + code: | + ctx.fillStyle = 'rgb(-100, -200, -300)'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = 'rgb(256, 300, 400)'; + ctx.fillRect(20, 10, 60, 10); + var imgdata1 = ctx.getImageData(10, 5, 1, 1); + @assert imgdata1.data[0] === 0; + @assert imgdata1.data[1] === 0; + @assert imgdata1.data[2] === 0; + var imgdata2 = ctx.getImageData(30, 15, 1, 1); + @assert imgdata2.data[0] === 255; + @assert imgdata2.data[1] === 255; + @assert imgdata2.data[2] === 255; + +- name: 2d.imageData.get.length + desc: getImageData() returns a correctly-sized Uint8ClampedArray + testing: + - 2d.pixelarray.length + code: | + var imgdata = ctx.getImageData(0, 0, 10, 10); + @assert imgdata.data.length === imgdata.width*imgdata.height*4; + +- name: 2d.imageData.get.order.cols + desc: getImageData() returns leftmost columns first + testing: + - 2d.pixelarray.order + code: | + ctx.fillStyle = '#fff'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#000'; + ctx.fillRect(0, 0, 2, 50); + var imgdata = ctx.getImageData(0, 0, 10, 10); + @assert imgdata.data[0] === 0; + @assert imgdata.data[Math.round(imgdata.width/2*4)] === 255; + @assert imgdata.data[Math.round((imgdata.height/2)*imgdata.width*4)] === 0; + +- name: 2d.imageData.get.order.rows + desc: getImageData() returns topmost rows first + testing: + - 2d.pixelarray.order + code: | + ctx.fillStyle = '#fff'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#000'; + ctx.fillRect(0, 0, 100, 2); + var imgdata = ctx.getImageData(0, 0, 10, 10); + @assert imgdata.data[0] === 0; + @assert imgdata.data[Math.floor(imgdata.width/2*4)] === 0; + @assert imgdata.data[(imgdata.height/2)*imgdata.width*4] === 255; + +- name: 2d.imageData.get.order.rgb + desc: getImageData() returns R then G then B + testing: + - 2d.pixelarray.order + - 2d.pixelarray.indexes + code: | + ctx.fillStyle = '#48c'; + ctx.fillRect(0, 0, 100, 50); + var imgdata = ctx.getImageData(0, 0, 10, 10); + @assert imgdata.data[0] === 0x44; + @assert imgdata.data[1] === 0x88; + @assert imgdata.data[2] === 0xCC; + @assert imgdata.data[3] === 255; + @assert imgdata.data[4] === 0x44; + @assert imgdata.data[5] === 0x88; + @assert imgdata.data[6] === 0xCC; + @assert imgdata.data[7] === 255; + +- name: 2d.imageData.get.order.alpha + desc: getImageData() returns A in the fourth component + testing: + - 2d.pixelarray.order + code: | + ctx.fillStyle = 'rgba(0, 0, 0, 0.5)'; + ctx.fillRect(0, 0, 100, 50); + var imgdata = ctx.getImageData(0, 0, 10, 10); + @assert imgdata.data[3] < 200; + @assert imgdata.data[3] > 100; + +- name: 2d.imageData.get.unaffected + desc: getImageData() is not affected by context state + testing: + - 2d.imageData.unaffected + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 50, 50) + ctx.fillStyle = '#f00'; + ctx.fillRect(50, 0, 50, 50) + ctx.save(); + ctx.translate(50, 0); + ctx.globalAlpha = 0.1; + ctx.globalCompositeOperation = 'destination-atop'; + ctx.shadowColor = '#f00'; + ctx.rect(0, 0, 5, 5); + ctx.clip(); + var imgdata = ctx.getImageData(0, 0, 50, 50); + ctx.restore(); + ctx.putImageData(imgdata, 50, 0); + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + expected: green + + +- name: 2d.imageData.object.properties + desc: ImageData objects have the right properties + testing: + - 2d.imageData.type + code: | + var imgdata = ctx.getImageData(0, 0, 10, 10); + @assert typeof(imgdata.width) === 'number'; + @assert typeof(imgdata.height) === 'number'; + @assert typeof(imgdata.data) === 'object'; + +- name: 2d.imageData.object.readonly + desc: ImageData objects properties are read-only + testing: + - 2d.imageData.type + code: | + var imgdata = ctx.getImageData(0, 0, 10, 10); + var w = imgdata.width; + var h = imgdata.height; + var d = imgdata.data; + imgdata.width = 123; + imgdata.height = 123; + imgdata.data = [100,100,100,100]; + @assert imgdata.width === w; + @assert imgdata.height === h; + @assert imgdata.data === d; + @assert imgdata.data[0] === 0; + @assert imgdata.data[1] === 0; + @assert imgdata.data[2] === 0; + @assert imgdata.data[3] === 0; + +- name: 2d.imageData.object.ctor + desc: ImageData does not have a usable constructor + testing: + - 2d.imageData.type + code: | + @assert window.ImageData !== undefined; + @assert throws TypeError new window.ImageData(1,1); + +- name: 2d.imageData.object.set + desc: ImageData.data can be modified + testing: + - 2d.pixelarray.modify + code: | + var imgdata = ctx.getImageData(0, 0, 10, 10); + imgdata.data[0] = 100; + @assert imgdata.data[0] === 100; + imgdata.data[0] = 200; + @assert imgdata.data[0] === 200; + +- name: 2d.imageData.object.undefined + desc: ImageData.data converts undefined to 0 + testing: + - 2d.pixelarray.modify + webidl: + - es-octet + code: | + var imgdata = ctx.getImageData(0, 0, 10, 10); + imgdata.data[0] = 100; + imgdata.data[0] = undefined; + @assert imgdata.data[0] === 0; + +- name: 2d.imageData.object.nan + desc: ImageData.data converts NaN to 0 + testing: + - 2d.pixelarray.modify + webidl: + - es-octet + code: | + var imgdata = ctx.getImageData(0, 0, 10, 10); + imgdata.data[0] = 100; + imgdata.data[0] = NaN; + @assert imgdata.data[0] === 0; + imgdata.data[0] = 100; + imgdata.data[0] = "cheese"; + @assert imgdata.data[0] === 0; + +- name: 2d.imageData.object.string + desc: ImageData.data converts strings to numbers with ToNumber + testing: + - 2d.pixelarray.modify + webidl: + - es-octet + code: | + var imgdata = ctx.getImageData(0, 0, 10, 10); + imgdata.data[0] = 100; + imgdata.data[0] = "110"; + @assert imgdata.data[0] === 110; + imgdata.data[0] = 100; + imgdata.data[0] = "0x78"; + @assert imgdata.data[0] === 120; + imgdata.data[0] = 100; + imgdata.data[0] = " +130e0 "; + @assert imgdata.data[0] === 130; + +- name: 2d.imageData.object.clamp + desc: ImageData.data clamps numbers to [0, 255] + testing: + - 2d.pixelarray.modify + webidl: + - es-octet + code: | + var imgdata = ctx.getImageData(0, 0, 10, 10); + + imgdata.data[0] = 100; + imgdata.data[0] = 300; + @assert imgdata.data[0] === 255; + imgdata.data[0] = 100; + imgdata.data[0] = -100; + @assert imgdata.data[0] === 0; + + imgdata.data[0] = 100; + imgdata.data[0] = 200+Math.pow(2, 32); + @assert imgdata.data[0] === 255; + imgdata.data[0] = 100; + imgdata.data[0] = -200-Math.pow(2, 32); + @assert imgdata.data[0] === 0; + + imgdata.data[0] = 100; + imgdata.data[0] = Math.pow(10, 39); + @assert imgdata.data[0] === 255; + imgdata.data[0] = 100; + imgdata.data[0] = -Math.pow(10, 39); + @assert imgdata.data[0] === 0; + + imgdata.data[0] = 100; + imgdata.data[0] = -Infinity; + @assert imgdata.data[0] === 0; + imgdata.data[0] = 100; + imgdata.data[0] = Infinity; + @assert imgdata.data[0] === 255; + +- name: 2d.imageData.object.round + desc: ImageData.data rounds numbers with round-to-zero + testing: + - 2d.pixelarray.modify + webidl: + - es-octet + code: | + var imgdata = ctx.getImageData(0, 0, 10, 10); + imgdata.data[0] = 0.499; + @assert imgdata.data[0] === 0; + imgdata.data[0] = 0.5; + @assert imgdata.data[0] === 0; + imgdata.data[0] = 0.501; + @assert imgdata.data[0] === 1; + imgdata.data[0] = 1.499; + @assert imgdata.data[0] === 1; + imgdata.data[0] = 1.5; + @assert imgdata.data[0] === 2; + imgdata.data[0] = 1.501; + @assert imgdata.data[0] === 2; + imgdata.data[0] = 2.5; + @assert imgdata.data[0] === 2; + imgdata.data[0] = 3.5; + @assert imgdata.data[0] === 4; + imgdata.data[0] = 252.5; + @assert imgdata.data[0] === 252; + imgdata.data[0] = 253.5; + @assert imgdata.data[0] === 254; + imgdata.data[0] = 254.5; + @assert imgdata.data[0] === 254; + imgdata.data[0] = 256.5; + @assert imgdata.data[0] === 255; + imgdata.data[0] = -0.5; + @assert imgdata.data[0] === 0; + imgdata.data[0] = -1.5; + @assert imgdata.data[0] === 0; + + + +- name: 2d.imageData.put.null + desc: putImageData() with null imagedata throws TypeError + testing: + - 2d.imageData.put.wrongtype + code: | + @assert throws TypeError ctx.putImageData(null, 0, 0); + +- name: 2d.imageData.put.nonfinite + desc: putImageData() throws TypeError if arguments are not finite + notes: *bindings + testing: + - 2d.imageData.put.nonfinite + code: | + var imgdata = ctx.getImageData(0, 0, 10, 10); + @nonfinite @assert throws TypeError ctx.putImageData(, <10 Infinity -Infinity NaN>, <10 Infinity -Infinity NaN>); + @nonfinite @assert throws TypeError ctx.putImageData(, <10 Infinity -Infinity NaN>, <10 Infinity -Infinity NaN>, <10 Infinity -Infinity NaN>, <10 Infinity -Infinity NaN>, <10 Infinity -Infinity NaN>, <10 Infinity -Infinity NaN>); + +- name: 2d.imageData.put.basic + desc: putImageData() puts image data from getImageData() onto the canvas + testing: + - 2d.imageData.put.normal + - 2d.imageData.put.3arg + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50) + var imgdata = ctx.getImageData(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50) + ctx.putImageData(imgdata, 0, 0); + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.imageData.put.created + desc: putImageData() puts image data from createImageData() onto the canvas + testing: + - 2d.imageData.put.normal + code: | + var imgdata = ctx.createImageData(100, 50); + for (var i = 0; i < imgdata.data.length; i += 4) { + imgdata.data[i] = 0; + imgdata.data[i+1] = 255; + imgdata.data[i+2] = 0; + imgdata.data[i+3] = 255; + } + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50) + ctx.putImageData(imgdata, 0, 0); + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.imageData.put.wrongtype + desc: putImageData() does not accept non-ImageData objects + testing: + - 2d.imageData.put.wrongtype + code: | + var imgdata = { width: 1, height: 1, data: [255, 0, 0, 255] }; + @assert throws TypeError ctx.putImageData(imgdata, 0, 0); + @assert throws TypeError ctx.putImageData("cheese", 0, 0); + @assert throws TypeError ctx.putImageData(42, 0, 0); + expected: green + +- name: 2d.imageData.put.cross + desc: putImageData() accepts image data got from a different canvas + testing: + - 2d.imageData.put.normal + code: | + var canvas2 = document.createElement('canvas'); + var ctx2 = canvas2.getContext('2d'); + ctx2.fillStyle = '#0f0'; + ctx2.fillRect(0, 0, 100, 50) + var imgdata = ctx2.getImageData(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50) + ctx.putImageData(imgdata, 0, 0); + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.imageData.put.alpha + desc: putImageData() puts non-solid image data correctly + testing: + - 2d.imageData.put.normal + code: | + ctx.fillStyle = 'rgba(0, 255, 0, 0.25)'; + ctx.fillRect(0, 0, 100, 50) + var imgdata = ctx.getImageData(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50) + ctx.putImageData(imgdata, 0, 0); + @assert pixel 50,25 ==~ 0,255,0,64; + expected: | + size 100 50 + cr.set_source_rgba(0, 1, 0, 0.25) + cr.rectangle(0, 0, 100, 50) + cr.fill() + +- name: 2d.imageData.put.modified + desc: putImageData() puts modified image data correctly + testing: + - 2d.imageData.put.normal + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50) + ctx.fillStyle = '#f00'; + ctx.fillRect(45, 20, 10, 10) + var imgdata = ctx.getImageData(45, 20, 10, 10); + for (var i = 0, len = imgdata.width*imgdata.height*4; i < len; i += 4) + { + imgdata.data[i] = 0; + imgdata.data[i+1] = 255; + } + ctx.putImageData(imgdata, 45, 20); + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.imageData.put.dirty.zero + desc: putImageData() with zero-sized dirty rectangle puts nothing + testing: + - 2d.imageData.put.normal + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50) + var imgdata = ctx.getImageData(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50) + ctx.putImageData(imgdata, 0, 0, 0, 0, 0, 0); + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.imageData.put.dirty.rect1 + desc: putImageData() only modifies areas inside the dirty rectangle, using width and height + testing: + - 2d.imageData.put.normal + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50) + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 20, 20) + + var imgdata = ctx.getImageData(0, 0, 100, 50); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50) + ctx.fillStyle = '#f00'; + ctx.fillRect(40, 20, 20, 20) + ctx.putImageData(imgdata, 40, 20, 0, 0, 20, 20); + + @assert pixel 50,25 ==~ 0,255,0,255; + @assert pixel 35,25 ==~ 0,255,0,255; + @assert pixel 65,25 ==~ 0,255,0,255; + @assert pixel 50,15 ==~ 0,255,0,255; + @assert pixel 50,45 ==~ 0,255,0,255; + expected: green + +- name: 2d.imageData.put.dirty.rect2 + desc: putImageData() only modifies areas inside the dirty rectangle, using x and y + testing: + - 2d.imageData.put.normal + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50) + ctx.fillStyle = '#0f0'; + ctx.fillRect(60, 30, 20, 20) + + var imgdata = ctx.getImageData(0, 0, 100, 50); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50) + ctx.fillStyle = '#f00'; + ctx.fillRect(40, 20, 20, 20) + ctx.putImageData(imgdata, -20, -10, 60, 30, 20, 20); + + @assert pixel 50,25 ==~ 0,255,0,255; + @assert pixel 35,25 ==~ 0,255,0,255; + @assert pixel 65,25 ==~ 0,255,0,255; + @assert pixel 50,15 ==~ 0,255,0,255; + @assert pixel 50,45 ==~ 0,255,0,255; + expected: green + +- name: 2d.imageData.put.dirty.negative + desc: putImageData() handles negative-sized dirty rectangles correctly + testing: + - 2d.imageData.put.normal + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50) + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 20, 20) + + var imgdata = ctx.getImageData(0, 0, 100, 50); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50) + ctx.fillStyle = '#f00'; + ctx.fillRect(40, 20, 20, 20) + ctx.putImageData(imgdata, 40, 20, 20, 20, -20, -20); + + @assert pixel 50,25 ==~ 0,255,0,255; + @assert pixel 35,25 ==~ 0,255,0,255; + @assert pixel 65,25 ==~ 0,255,0,255; + @assert pixel 50,15 ==~ 0,255,0,255; + @assert pixel 50,45 ==~ 0,255,0,255; + expected: green + +- name: 2d.imageData.put.dirty.outside + desc: putImageData() handles dirty rectangles outside the canvas correctly + testing: + - 2d.imageData.put.normal + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50) + + var imgdata = ctx.getImageData(0, 0, 100, 50); + + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50) + + ctx.putImageData(imgdata, 100, 20, 20, 20, -20, -20); + ctx.putImageData(imgdata, 200, 200, 0, 0, 100, 50); + ctx.putImageData(imgdata, 40, 20, -30, -20, 30, 20); + ctx.putImageData(imgdata, -30, 20, 0, 0, 30, 20); + + @assert pixel 50,25 ==~ 0,255,0,255; + @assert pixel 98,15 ==~ 0,255,0,255; + @assert pixel 98,25 ==~ 0,255,0,255; + @assert pixel 98,45 ==~ 0,255,0,255; + @assert pixel 1,5 ==~ 0,255,0,255; + @assert pixel 1,25 ==~ 0,255,0,255; + @assert pixel 1,45 ==~ 0,255,0,255; + expected: green + +- name: 2d.imageData.put.unchanged + desc: putImageData(getImageData(...), ...) has no effect + testing: + - 2d.imageData.unchanged + code: | + var i = 0; + for (var y = 0; y < 16; ++y) { + for (var x = 0; x < 16; ++x, ++i) { + ctx.fillStyle = 'rgba(' + i + ',' + (Math.floor(i*1.5) % 256) + ',' + (Math.floor(i*23.3) % 256) + ',' + (i/256) + ')'; + ctx.fillRect(x, y, 1, 1); + } + } + var imgdata1 = ctx.getImageData(0.1, 0.2, 15.8, 15.9); + var olddata = []; + for (var i = 0; i < imgdata1.data.length; ++i) + olddata[i] = imgdata1.data[i]; + + ctx.putImageData(imgdata1, 0.1, 0.2); + + var imgdata2 = ctx.getImageData(0.1, 0.2, 15.8, 15.9); + for (var i = 0; i < imgdata2.data.length; ++i) { + @assert olddata[i] === imgdata2.data[i]; + } + +- name: 2d.imageData.put.unaffected + desc: putImageData() is not affected by context state + testing: + - 2d.imageData.unaffected + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50) + var imgdata = ctx.getImageData(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50) + ctx.globalAlpha = 0.1; + ctx.globalCompositeOperation = 'destination-atop'; + ctx.shadowColor = '#f00'; + ctx.shadowBlur = 1; + ctx.translate(100, 50); + ctx.scale(0.1, 0.1); + ctx.putImageData(imgdata, 0, 0); + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.imageData.put.clip + desc: putImageData() is not affected by clipping regions + testing: + - 2d.imageData.unaffected + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50) + var imgdata = ctx.getImageData(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50) + ctx.beginPath(); + ctx.rect(0, 0, 50, 50); + ctx.clip(); + ctx.putImageData(imgdata, 0, 0); + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + expected: green + +- name: 2d.imageData.put.path + desc: putImageData() does not affect the current path + testing: + - 2d.imageData.put.normal + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50) + ctx.rect(0, 0, 100, 50); + var imgdata = ctx.getImageData(0, 0, 100, 50); + ctx.putImageData(imgdata, 0, 0); + ctx.fillStyle = '#0f0'; + ctx.fill(); + @assert pixel 50,25 ==~ 0,255,0,255; + expected: green diff --git a/testing/web-platform/tests/2dcontext/tools/tests2dtext.yaml b/testing/web-platform/tests/2dcontext/tools/tests2dtext.yaml new file mode 100644 index 000000000..96c65265c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/tools/tests2dtext.yaml @@ -0,0 +1,1013 @@ +# Copyright (c) 2010 Philip Taylor +# Released under the BSD license and W3C Test Suite License: see LICENSE.txt + +- name: 2d.text.font.parse.basic + testing: + - 2d.text.font.parse + - 2d.text.font.get + code: | + ctx.font = '20px serif'; + @assert ctx.font === '20px serif'; + + ctx.font = '20PX SERIF'; + @assert ctx.font === '20px serif'; @moz-todo + +- name: 2d.text.font.parse.complex + testing: + - 2d.text.font.parse + - 2d.text.font.get + - 2d.text.font.lineheight + code: | + ctx.font = 'small-caps italic 400 12px/2 Unknown Font, sans-serif'; + @assert ctx.font === 'italic small-caps 12px "Unknown Font", sans-serif'; @moz-todo + + # TODO: + # 2d.text.font.parse.size.absolute + # xx-small x-small small medium large x-large xx-large + # 2d.text.font.parse.size.relative + # smaller larger + # 2d.text.font.parse.size.length.relative + # em ex px + # 2d.text.font.parse.size.length.absolute + # in cm mm pt pc + +- name: 2d.text.font.parse.size.percentage + testing: + - 2d.text.font.parse + - 2d.text.font.get + - 2d.text.font.fontsize + - 2d.text.font.size + canvas: 'style="font-size: 144px" width="100" height="50"' + code: | + ctx.font = '50% serif'; + @assert ctx.font === '72px serif'; @moz-todo + canvas.setAttribute('style', 'font-size: 100px'); + @assert ctx.font === '72px serif'; @moz-todo + +- name: 2d.text.font.parse.size.percentage.default + testing: + - 2d.text.font.undefined + code: | + var canvas2 = document.createElement('canvas'); + var ctx2 = canvas2.getContext('2d'); + ctx2.font = '1000% serif'; + @assert ctx2.font === '100px serif'; @moz-todo + +- name: 2d.text.font.parse.system + desc: System fonts must be computed to explicit values + testing: + - 2d.text.font.parse + - 2d.text.font.get + - 2d.text.font.systemfonts + code: | + ctx.font = 'message-box'; + @assert ctx.font !== 'message-box'; + +- name: 2d.text.font.parse.invalid + testing: + - 2d.text.font.invalid + code: | + ctx.font = '20px serif'; + @assert ctx.font === '20px serif'; + + ctx.font = '20px serif'; + ctx.font = 'bogus'; + @assert ctx.font === '20px serif'; + + ctx.font = '20px serif'; + ctx.font = 'inherit'; + @assert ctx.font === '20px serif'; + + ctx.font = '20px serif'; + ctx.font = '10px {bogus}'; + @assert ctx.font === '20px serif'; + + ctx.font = '20px serif'; + ctx.font = '10px initial'; + @assert ctx.font === '20px serif'; @moz-todo + + ctx.font = '20px serif'; + ctx.font = '10px default'; + @assert ctx.font === '20px serif'; @moz-todo + + ctx.font = '20px serif'; + ctx.font = '10px inherit'; + @assert ctx.font === '20px serif'; + + ctx.font = '20px serif'; + ctx.font = '1em serif; background: green; margin: 10px'; + @assert ctx.font === '20px serif'; + +- name: 2d.text.font.default + testing: + - 2d.text.font.default + code: | + @assert ctx.font === '10px sans-serif'; + + + +- name: 2d.text.align.valid + testing: + - 2d.text.align.get + - 2d.text.align.set + code: | + ctx.textAlign = 'start'; + @assert ctx.textAlign === 'start'; + + ctx.textAlign = 'end'; + @assert ctx.textAlign === 'end'; + + ctx.textAlign = 'left'; + @assert ctx.textAlign === 'left'; + + ctx.textAlign = 'right'; + @assert ctx.textAlign === 'right'; + + ctx.textAlign = 'center'; + @assert ctx.textAlign === 'center'; + +- name: 2d.text.align.invalid + testing: + - 2d.text.align.invalid + code: | + ctx.textAlign = 'start'; + ctx.textAlign = 'bogus'; + @assert ctx.textAlign === 'start'; + + ctx.textAlign = 'start'; + ctx.textAlign = 'END'; + @assert ctx.textAlign === 'start'; + + ctx.textAlign = 'start'; + ctx.textAlign = 'end '; + @assert ctx.textAlign === 'start'; + + ctx.textAlign = 'start'; + ctx.textAlign = 'end\0'; + @assert ctx.textAlign === 'start'; + +- name: 2d.text.align.default + testing: + - 2d.text.align.default + code: | + @assert ctx.textAlign === 'start'; + + +- name: 2d.text.baseline.valid + testing: + - 2d.text.baseline.get + - 2d.text.baseline.set + code: | + ctx.textBaseline = 'top'; + @assert ctx.textBaseline === 'top'; + + ctx.textBaseline = 'hanging'; + @assert ctx.textBaseline === 'hanging'; + + ctx.textBaseline = 'middle'; + @assert ctx.textBaseline === 'middle'; + + ctx.textBaseline = 'alphabetic'; + @assert ctx.textBaseline === 'alphabetic'; + + ctx.textBaseline = 'ideographic'; + @assert ctx.textBaseline === 'ideographic'; + + ctx.textBaseline = 'bottom'; + @assert ctx.textBaseline === 'bottom'; + +- name: 2d.text.baseline.invalid + testing: + - 2d.text.baseline.invalid + code: | + ctx.textBaseline = 'top'; + ctx.textBaseline = 'bogus'; + @assert ctx.textBaseline === 'top'; + + ctx.textBaseline = 'top'; + ctx.textBaseline = 'MIDDLE'; + @assert ctx.textBaseline === 'top'; + + ctx.textBaseline = 'top'; + ctx.textBaseline = 'middle '; + @assert ctx.textBaseline === 'top'; + + ctx.textBaseline = 'top'; + ctx.textBaseline = 'middle\0'; + @assert ctx.textBaseline === 'top'; + +- name: 2d.text.baseline.default + testing: + - 2d.text.baseline.default + code: | + @assert ctx.textBaseline === 'alphabetic'; + + + + + +- name: 2d.text.draw.fill.basic + desc: fillText draws filled text + manual: + testing: + - 2d.text.draw + - 2d.text.draw.fill + code: | + ctx.fillStyle = '#000'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.strokeStyle = '#f00'; + ctx.font = '35px Arial, sans-serif'; + ctx.fillText('PASS', 5, 35); + expected: &passfill | + size 100 50 + cr.set_source_rgb(0, 0, 0) + cr.rectangle(0, 0, 100, 50) + cr.fill() + cr.set_source_rgb(0, 1, 0) + cr.select_font_face("Arial") + cr.set_font_size(35) + cr.translate(5, 35) + cr.text_path("PASS") + cr.fill() + +- name: 2d.text.draw.fill.unaffected + desc: fillText does not start a new path or subpath + testing: + - 2d.text.draw.fill + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.moveTo(0, 0); + ctx.lineTo(100, 0); + + ctx.font = '35px Arial, sans-serif'; + ctx.fillText('FAIL', 5, 35); + + ctx.lineTo(100, 50); + ctx.lineTo(0, 50); + ctx.fillStyle = '#0f0'; + ctx.fill(); + + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 5,45 == 0,255,0,255; + expected: green + +- name: 2d.text.draw.fill.rtl + desc: fillText respects Right-To-Left Override characters + manual: + testing: + - 2d.text.draw + code: | + ctx.fillStyle = '#000'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.strokeStyle = '#f00'; + ctx.font = '35px Arial, sans-serif'; + ctx.fillText('\u202eFAIL \xa0 \xa0 SSAP', 5, 35); + expected: *passfill + +- name: 2d.text.draw.fill.maxWidth.large + desc: fillText handles maxWidth correctly + manual: + testing: + - 2d.text.draw.maxwidth + code: | + ctx.fillStyle = '#000'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.font = '35px Arial, sans-serif'; + ctx.fillText('PASS', 5, 35, 200); + expected: *passfill + +- name: 2d.text.draw.fill.maxWidth.small + desc: fillText handles maxWidth correctly + testing: + - 2d.text.draw.maxwidth + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.font = '35px Arial, sans-serif'; + ctx.fillText('fail fail fail fail fail', -100, 35, 90); + _assertGreen(ctx, 100, 50); + expected: green + +- name: 2d.text.draw.fill.maxWidth.zero + desc: fillText handles maxWidth correctly + testing: + - 2d.text.draw.maxwidth + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.font = '35px Arial, sans-serif'; + ctx.fillText('fail fail fail fail fail', 5, 35, 0); + _assertGreen(ctx, 100, 50); + expected: green + +- name: 2d.text.draw.fill.maxWidth.negative + desc: fillText handles maxWidth correctly + testing: + - 2d.text.draw.maxwidth + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.font = '35px Arial, sans-serif'; + ctx.fillText('fail fail fail fail fail', 5, 35, -1); + _assertGreen(ctx, 100, 50); + expected: green + +- name: 2d.text.draw.fill.maxWidth.NaN + desc: fillText handles maxWidth correctly + testing: + - 2d.text.draw.maxwidth + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.font = '35px Arial, sans-serif'; + ctx.fillText('fail fail fail fail fail', 5, 35, NaN); + _assertGreen(ctx, 100, 50); + expected: green + +- name: 2d.text.draw.stroke.basic + desc: strokeText draws stroked text + manual: + testing: + - 2d.text.draw + - 2d.text.draw.stroke + code: | + ctx.fillStyle = '#000'; + ctx.fillRect(0, 0, 100, 50); + ctx.strokeStyle = '#0f0'; + ctx.fillStyle = '#f00'; + ctx.lineWidth = 1; + ctx.font = '35px Arial, sans-serif'; + ctx.strokeText('PASS', 5, 35); + expected: | + size 100 50 + cr.set_source_rgb(0, 0, 0) + cr.rectangle(0, 0, 100, 50) + cr.fill() + cr.set_source_rgb(0, 1, 0) + cr.select_font_face("Arial") + cr.set_font_size(35) + cr.set_line_width(1) + cr.translate(5, 35) + cr.text_path("PASS") + cr.stroke() + +- name: 2d.text.draw.stroke.unaffected + desc: strokeText does not start a new path or subpath + testing: + - 2d.text.draw.stroke + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + + ctx.moveTo(0, 0); + ctx.lineTo(100, 0); + + ctx.font = '35px Arial, sans-serif'; + ctx.strokeStyle = '#f00'; + ctx.strokeText('FAIL', 5, 35); + + ctx.lineTo(100, 50); + ctx.lineTo(0, 50); + ctx.fillStyle = '#0f0'; + ctx.fill(); + + @assert pixel 50,25 == 0,255,0,255; + @assert pixel 5,45 == 0,255,0,255; + expected: green + +- name: 2d.text.draw.kern.consistent + desc: Stroked and filled text should have exactly the same kerning so it overlaps + manual: + testing: + - 2d.text.draw + code: | + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.strokeStyle = '#0f0'; + ctx.lineWidth = 3; + ctx.font = '20px Arial, sans-serif'; + ctx.fillText('VAVAVAVAVAVAVA', -50, 25); + ctx.fillText('ToToToToToToTo', -50, 45); + ctx.strokeText('VAVAVAVAVAVAVA', -50, 25); + ctx.strokeText('ToToToToToToTo', -50, 45); + expected: green + +# CanvasTest is: +# A = (0, 0) to (1em, 0.75em) (above baseline) +# B = (0, 0) to (1em, -0.25em) (below baseline) +# C = (0, -0.25em) to (1em, 0.75em) (the em square) plus some Xs above and below +# D = (0, -0.25em) to (1em, 0.75em) (the em square) plus some Xs left and right +# E = (0, -0.25em) to (1em, 0.75em) (the em square) +# space = empty, 1em wide +# +# At 50px, "E" will fill the canvas vertically +# At 67px, "A" will fill the canvas vertically +# +# Ideographic baseline is 0.125em above alphabetic +# Mathematical baseline is 0.375em above alphabetic +# Hanging baseline is 0.500em above alphabetic + +# WebKit doesn't block onload on font loads, so we try to make it a bit more reliable +# by waiting with setTimeout after load before drawing + +- name: 2d.text.draw.fill.maxWidth.fontface + desc: fillText works on @font-face fonts + testing: + - 2d.text.draw.maxwidth + fonts: + - CanvasTest + code: | + ctx.font = '50px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#0f0'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#f00'; + ctx.fillText('EEEE', -50, 37.5, 40); + @assert pixel 5,5 ==~ 0,255,0,255; + @assert pixel 95,5 ==~ 0,255,0,255; + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + }), 500); + expected: green + +- name: 2d.text.draw.fill.maxWidth.bound + desc: fillText handles maxWidth based on line size, not bounding box size + testing: + - 2d.text.draw.maxwidth + fonts: + - CanvasTest + code: | + ctx.font = '50px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.fillText('DD', 0, 37.5, 100); + @assert pixel 5,5 ==~ 0,255,0,255; + @assert pixel 95,5 ==~ 0,255,0,255; + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + }), 500); + expected: green + +- name: 2d.text.draw.fontface + testing: + - 2d.text.font.fontface + fonts: + - CanvasTest + code: | + ctx.font = '67px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.fillText('AA', 0, 50); + @assert pixel 5,5 ==~ 0,255,0,255; + @assert pixel 95,5 ==~ 0,255,0,255; + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + }), 500); + expected: green + +- name: 2d.text.draw.fontface.repeat + desc: Draw with the font immediately, then wait a bit until and draw again. (This crashes some version of WebKit.) + testing: + - 2d.text.font.fontface + fonts: + - CanvasTest + fonthack: 0 + code: | + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.font = '67px CanvasTest'; + ctx.fillStyle = '#0f0'; + ctx.fillText('AA', 0, 50); + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillText('AA', 0, 50); + @assert pixel 5,5 ==~ 0,255,0,255; + @assert pixel 95,5 ==~ 0,255,0,255; + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + }), 500); + expected: green + +- name: 2d.text.draw.fontface.notinpage + desc: "@font-face fonts should work even if they are not used in the page" + testing: + - 2d.text.font.fontface + fonts: + - CanvasTest + fonthack: 0 + code: | + ctx.font = '67px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.fillText('AA', 0, 50); + @assert pixel 5,5 ==~ 0,255,0,255; @moz-todo + @assert pixel 95,5 ==~ 0,255,0,255; @moz-todo + @assert pixel 25,25 ==~ 0,255,0,255; @moz-todo + @assert pixel 75,25 ==~ 0,255,0,255; @moz-todo + }), 500); + expected: green + +- name: 2d.text.draw.baseline.top + desc: textBaseline top is the top of the em square (not the bounding box) + testing: + - 2d.text.baseline.top + fonts: + - CanvasTest + code: | + ctx.font = '50px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.textBaseline = 'top'; + ctx.fillText('CC', 0, 0); + @assert pixel 5,5 ==~ 0,255,0,255; + @assert pixel 95,5 ==~ 0,255,0,255; + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + @assert pixel 5,45 ==~ 0,255,0,255; + @assert pixel 95,45 ==~ 0,255,0,255; + }), 500); + expected: green + +- name: 2d.text.draw.baseline.bottom + desc: textBaseline bottom is the bottom of the em square (not the bounding box) + testing: + - 2d.text.baseline.bottom + fonts: + - CanvasTest + code: | + ctx.font = '50px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.textBaseline = 'bottom'; + ctx.fillText('CC', 0, 50); + @assert pixel 5,5 ==~ 0,255,0,255; + @assert pixel 95,5 ==~ 0,255,0,255; + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + @assert pixel 5,45 ==~ 0,255,0,255; + @assert pixel 95,45 ==~ 0,255,0,255; + }), 500); + expected: green + +- name: 2d.text.draw.baseline.middle + desc: textBaseline middle is the middle of the em square (not the bounding box) + testing: + - 2d.text.baseline.middle + fonts: + - CanvasTest + code: | + ctx.font = '50px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.textBaseline = 'middle'; + ctx.fillText('CC', 0, 25); + @assert pixel 5,5 ==~ 0,255,0,255; + @assert pixel 95,5 ==~ 0,255,0,255; + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + @assert pixel 5,45 ==~ 0,255,0,255; + @assert pixel 95,45 ==~ 0,255,0,255; + }), 500); + expected: green + +- name: 2d.text.draw.baseline.alphabetic + testing: + - 2d.text.baseline.alphabetic + fonts: + - CanvasTest + code: | + ctx.font = '50px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.textBaseline = 'alphabetic'; + ctx.fillText('CC', 0, 37.5); + @assert pixel 5,5 ==~ 0,255,0,255; + @assert pixel 95,5 ==~ 0,255,0,255; + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + @assert pixel 5,45 ==~ 0,255,0,255; + @assert pixel 95,45 ==~ 0,255,0,255; + }), 500); + expected: green + +- name: 2d.text.draw.baseline.ideographic + testing: + - 2d.text.baseline.ideographic + fonts: + - CanvasTest + code: | + ctx.font = '50px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.textBaseline = 'ideographic'; + ctx.fillText('CC', 0, 31.25); + @assert pixel 5,5 ==~ 0,255,0,255; + @assert pixel 95,5 ==~ 0,255,0,255; + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + @assert pixel 5,45 ==~ 0,255,0,255; @moz-todo + @assert pixel 95,45 ==~ 0,255,0,255; @moz-todo + }), 500); + expected: green + +- name: 2d.text.draw.baseline.hanging + testing: + - 2d.text.baseline.hanging + fonts: + - CanvasTest + code: | + ctx.font = '50px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.textBaseline = 'hanging'; + ctx.fillText('CC', 0, 12.5); + @assert pixel 5,5 ==~ 0,255,0,255; @moz-todo + @assert pixel 95,5 ==~ 0,255,0,255; @moz-todo + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + @assert pixel 5,45 ==~ 0,255,0,255; + @assert pixel 95,45 ==~ 0,255,0,255; + }), 500); + expected: green + +- name: 2d.text.draw.align.left + desc: textAlign left is the left of the first em square (not the bounding box) + testing: + - 2d.text.align.left + fonts: + - CanvasTest + code: | + ctx.font = '50px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.textAlign = 'left'; + ctx.fillText('DD', 0, 37.5); + @assert pixel 5,5 ==~ 0,255,0,255; + @assert pixel 95,5 ==~ 0,255,0,255; + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + @assert pixel 5,45 ==~ 0,255,0,255; + @assert pixel 95,45 ==~ 0,255,0,255; + }), 500); + expected: green + +- name: 2d.text.draw.align.right + desc: textAlign right is the right of the last em square (not the bounding box) + testing: + - 2d.text.align.right + fonts: + - CanvasTest + code: | + ctx.font = '50px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.textAlign = 'right'; + ctx.fillText('DD', 100, 37.5); + @assert pixel 5,5 ==~ 0,255,0,255; + @assert pixel 95,5 ==~ 0,255,0,255; + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + @assert pixel 5,45 ==~ 0,255,0,255; + @assert pixel 95,45 ==~ 0,255,0,255; + }), 500); + expected: green + +- name: 2d.text.draw.align.start.ltr + desc: textAlign start with ltr is the left edge + testing: + - 2d.text.align.left + fonts: + - CanvasTest + canvas: width="100" height="50" dir="ltr" + code: | + ctx.font = '50px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.textAlign = 'start'; + ctx.fillText('DD', 0, 37.5); + @assert pixel 5,5 ==~ 0,255,0,255; + @assert pixel 95,5 ==~ 0,255,0,255; + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + @assert pixel 5,45 ==~ 0,255,0,255; + @assert pixel 95,45 ==~ 0,255,0,255; + }), 500); + expected: green + +- name: 2d.text.draw.align.start.rtl + desc: textAlign start with rtl is the right edge + testing: + - 2d.text.align.right + - 2d.text.draw.direction + fonts: + - CanvasTest + canvas: width="100" height="50" dir="rtl" + code: | + ctx.font = '50px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.textAlign = 'start'; + ctx.fillText('DD', 100, 37.5); + @assert pixel 5,5 ==~ 0,255,0,255; + @assert pixel 95,5 ==~ 0,255,0,255; + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + @assert pixel 5,45 ==~ 0,255,0,255; + @assert pixel 95,45 ==~ 0,255,0,255; + }), 500); + expected: green + +- name: 2d.text.draw.align.end.ltr + desc: textAlign end with ltr is the right edge + testing: + - 2d.text.align.right + fonts: + - CanvasTest + canvas: width="100" height="50" dir="ltr" + code: | + ctx.font = '50px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.textAlign = 'end'; + ctx.fillText('DD', 100, 37.5); + @assert pixel 5,5 ==~ 0,255,0,255; + @assert pixel 95,5 ==~ 0,255,0,255; + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + @assert pixel 5,45 ==~ 0,255,0,255; + @assert pixel 95,45 ==~ 0,255,0,255; + }), 500); + expected: green + +- name: 2d.text.draw.align.end.rtl + desc: textAlign end with rtl is the left edge + testing: + - 2d.text.align.left + - 2d.text.draw.direction + fonts: + - CanvasTest + canvas: width="100" height="50" dir="rtl" + code: | + ctx.font = '50px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.textAlign = 'end'; + ctx.fillText('DD', 0, 37.5); + @assert pixel 5,5 ==~ 0,255,0,255; + @assert pixel 95,5 ==~ 0,255,0,255; + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + @assert pixel 5,45 ==~ 0,255,0,255; + @assert pixel 95,45 ==~ 0,255,0,255; + }), 500); + expected: green + +- name: 2d.text.draw.align.center + desc: textAlign center is the center of the em squares (not the bounding box) + testing: + - 2d.text.align.center + fonts: + - CanvasTest + code: | + ctx.font = '50px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.textAlign = 'center'; + ctx.fillText('DD', 50, 37.5); + @assert pixel 5,5 ==~ 0,255,0,255; + @assert pixel 95,5 ==~ 0,255,0,255; + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + @assert pixel 5,45 ==~ 0,255,0,255; + @assert pixel 95,45 ==~ 0,255,0,255; + }), 500); + expected: green + + +- name: 2d.text.draw.space.basic + desc: U+0020 is rendered the correct size (1em wide) + testing: + - 2d.text.draw.spaces + fonts: + - CanvasTest + code: | + ctx.font = '50px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.fillText('E EE', -100, 37.5); + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + }), 500); + expected: green + +- name: 2d.text.draw.space.collapse.space + desc: Space characters are converted to U+0020, and collapsed (per CSS) + testing: + - 2d.text.draw.spaces + fonts: + - CanvasTest + code: | + ctx.font = '50px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.fillText('E EE', -100, 37.5); + @assert pixel 25,25 ==~ 0,255,0,255; @moz-todo + @assert pixel 75,25 ==~ 0,255,0,255; + }), 500); + expected: green + +- name: 2d.text.draw.space.collapse.other + desc: Space characters are converted to U+0020, and collapsed (per CSS) + testing: + - 2d.text.draw.spaces + fonts: + - CanvasTest + code: | + ctx.font = '50px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.fillText('E \x09\x0a\x0c\x0d \x09\x0a\x0c\x0dEE', -100, 37.5); + @assert pixel 25,25 ==~ 0,255,0,255; @moz-todo + @assert pixel 75,25 ==~ 0,255,0,255; @moz-todo + }), 500); + expected: green + +- name: 2d.text.draw.space.collapse.nonspace + desc: Non-space characters are not converted to U+0020 and collapsed + testing: + - 2d.text.draw.spaces + fonts: + - CanvasTest + code: | + ctx.font = '50px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.fillText('E\x0b EE', -150, 37.5); + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; + }), 500); + expected: green + +- name: 2d.text.draw.space.collapse.start + desc: Space characters at the start of a line are collapsed (per CSS) + testing: + - 2d.text.draw.spaces + fonts: + - CanvasTest + code: | + ctx.font = '50px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.fillText(' EE', 0, 37.5); + @assert pixel 25,25 ==~ 0,255,0,255; @moz-todo + @assert pixel 75,25 ==~ 0,255,0,255; + }), 500); + expected: green + +- name: 2d.text.draw.space.collapse.end + desc: Space characters at the end of a line are collapsed (per CSS) + testing: + - 2d.text.draw.spaces + fonts: + - CanvasTest + code: | + ctx.font = '50px CanvasTest'; + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.fillStyle = '#f00'; + ctx.fillRect(0, 0, 100, 50); + ctx.fillStyle = '#0f0'; + ctx.textAlign = 'right'; + ctx.fillText('EE ', 100, 37.5); + @assert pixel 25,25 ==~ 0,255,0,255; + @assert pixel 75,25 ==~ 0,255,0,255; @moz-todo + }), 500); + expected: green + + + + +- name: 2d.text.measure.width.basic + testing: + - 2d.text.measure + fonts: + - CanvasTest + code: | + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.font = '50px CanvasTest'; + @assert ctx.measureText('A').width === 50; + @assert ctx.measureText('AA').width === 100; + @assert ctx.measureText('ABCD').width === 200; + + ctx.font = '100px CanvasTest'; + @assert ctx.measureText('A').width === 100; + }), 500); + +- name: 2d.text.measure.width.empty + desc: The empty string has zero width + testing: + - 2d.text.measure + fonts: + - CanvasTest + code: | + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.font = '50px CanvasTest'; + @assert ctx.measureText("").width === 0; + }), 500); + +- name: 2d.text.measure.width.space + desc: Space characters are converted to U+0020 and collapsed (per CSS) + testing: + - 2d.text.measure.spaces + fonts: + - CanvasTest + code: | + deferTest(); + setTimeout(t.step_func_done(function () { + ctx.font = '50px CanvasTest'; + @assert ctx.measureText('A B').width === 150; + @assert ctx.measureText('A B').width === 150; @moz-todo + @assert ctx.measureText('A \x09\x0a\x0c\x0d \x09\x0a\x0c\x0dB').width === 150; @moz-todo + @assert ctx.measureText('A \x0b B').width >= 200; + + @assert ctx.measureText(' AB').width === 100; @moz-todo + @assert ctx.measureText('AB ').width === 100; @moz-todo + }), 500); + +# TODO: shadows, alpha, composite, clip diff --git a/testing/web-platform/tests/2dcontext/transformations/.gitkeep b/testing/web-platform/tests/2dcontext/transformations/.gitkeep new file mode 100644 index 000000000..e69de29bb diff --git a/testing/web-platform/tests/2dcontext/transformations/2d.transformation.order.html b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.order.html new file mode 100644 index 000000000..8209ad66d --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.order.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.transformation.order + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.transformation.order

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Transformations are applied in the right order

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.direction.html b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.direction.html new file mode 100644 index 000000000..5113fa238 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.direction.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.transformation.rotate.direction + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.transformation.rotate.direction

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        rotate() is clockwise

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.nonfinite.html b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.nonfinite.html new file mode 100644 index 000000000..1726dcf5b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.nonfinite.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.transformation.rotate.nonfinite + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.transformation.rotate.nonfinite

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          rotate() with Infinity/NaN is ignored

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.radians.html b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.radians.html new file mode 100644 index 000000000..8cfeb6fd1 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.radians.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.transformation.rotate.radians + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.transformation.rotate.radians

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            rotate() uses radians

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.wrap.html b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.wrap.html new file mode 100644 index 000000000..fbfba2a29 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.wrap.html @@ -0,0 +1,38 @@ + + +Canvas test: 2d.transformation.rotate.wrap + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.transformation.rotate.wrap

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              rotate() wraps large positive values correctly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.wrapnegative.html b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.wrapnegative.html new file mode 100644 index 000000000..a695e7b39 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.wrapnegative.html @@ -0,0 +1,35 @@ + + +Canvas test: 2d.transformation.rotate.wrapnegative + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.transformation.rotate.wrapnegative

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                rotate() wraps large negative values correctly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.zero.html b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.zero.html new file mode 100644 index 000000000..cd74260e7 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.rotate.zero.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.transformation.rotate.zero + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.transformation.rotate.zero

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  rotate() by 0 does nothing

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.basic.html b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.basic.html new file mode 100644 index 000000000..a083a6514 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.basic.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.transformation.scale.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.transformation.scale.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    scale() works

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.large.html b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.large.html new file mode 100644 index 000000000..926530d1f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.large.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.transformation.scale.large + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.transformation.scale.large

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      scale() with large scale factors works

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Not really that large at all, but it hits the limits in Firefox. +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.multiple.html b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.multiple.html new file mode 100644 index 000000000..9856798be --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.multiple.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.transformation.scale.multiple + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.transformation.scale.multiple

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Multiple scale()s combine

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.negative.html b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.negative.html new file mode 100644 index 000000000..af3285165 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.negative.html @@ -0,0 +1,42 @@ + + +Canvas test: 2d.transformation.scale.negative + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.transformation.scale.negative

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          scale() with negative scale factors works

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.nonfinite.html b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.nonfinite.html new file mode 100644 index 000000000..b9788885f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.nonfinite.html @@ -0,0 +1,42 @@ + + +Canvas test: 2d.transformation.scale.nonfinite + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.transformation.scale.nonfinite

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            scale() with Infinity/NaN is ignored

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.zero.html b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.zero.html new file mode 100644 index 000000000..80e79a988 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.scale.zero.html @@ -0,0 +1,46 @@ + + +Canvas test: 2d.transformation.scale.zero + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.transformation.scale.zero

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              scale() with a scale factor of zero works

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/transformations/2d.transformation.setTransform.multiple.html b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.setTransform.multiple.html new file mode 100644 index 000000000..79caa6308 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.setTransform.multiple.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.transformation.setTransform.multiple + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.transformation.setTransform.multiple

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/transformations/2d.transformation.setTransform.nonfinite.html b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.setTransform.nonfinite.html new file mode 100644 index 000000000..4b5ebd6c7 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.setTransform.nonfinite.html @@ -0,0 +1,110 @@ + + +Canvas test: 2d.transformation.setTransform.nonfinite + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  2d.transformation.setTransform.nonfinite

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  setTransform() with Infinity/NaN is ignored

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + diff --git a/testing/web-platform/tests/2dcontext/transformations/2d.transformation.setTransform.skewed.html b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.setTransform.skewed.html new file mode 100644 index 000000000..d411e544b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.setTransform.skewed.html @@ -0,0 +1,55 @@ + + +Canvas test: 2d.transformation.setTransform.skewed + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    2d.transformation.setTransform.skewed

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + diff --git a/testing/web-platform/tests/2dcontext/transformations/2d.transformation.transform.identity.html b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.transform.identity.html new file mode 100644 index 000000000..bf88557b9 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.transform.identity.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.transformation.transform.identity + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      2d.transformation.transform.identity

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      transform() with the identity matrix does nothing

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + diff --git a/testing/web-platform/tests/2dcontext/transformations/2d.transformation.transform.multiply.html b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.transform.multiply.html new file mode 100644 index 000000000..0313602ab --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.transform.multiply.html @@ -0,0 +1,34 @@ + + +Canvas test: 2d.transformation.transform.multiply + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        2d.transformation.transform.multiply

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        transform() multiplies the CTM

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + diff --git a/testing/web-platform/tests/2dcontext/transformations/2d.transformation.transform.nonfinite.html b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.transform.nonfinite.html new file mode 100644 index 000000000..1b12766cd --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.transform.nonfinite.html @@ -0,0 +1,110 @@ + + +Canvas test: 2d.transformation.transform.nonfinite + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          2d.transformation.transform.nonfinite

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          transform() with Infinity/NaN is ignored

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + diff --git a/testing/web-platform/tests/2dcontext/transformations/2d.transformation.transform.skewed.html b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.transform.skewed.html new file mode 100644 index 000000000..cf723c7c2 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.transform.skewed.html @@ -0,0 +1,55 @@ + + +Canvas test: 2d.transformation.transform.skewed + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            2d.transformation.transform.skewed

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            transform() with skewy matrix transforms correctly

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + diff --git a/testing/web-platform/tests/2dcontext/transformations/2d.transformation.translate.basic.html b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.translate.basic.html new file mode 100644 index 000000000..0238f8d0b --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.translate.basic.html @@ -0,0 +1,33 @@ + + +Canvas test: 2d.transformation.translate.basic + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              2d.transformation.translate.basic

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              translate() works

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + diff --git a/testing/web-platform/tests/2dcontext/transformations/2d.transformation.translate.nonfinite.html b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.translate.nonfinite.html new file mode 100644 index 000000000..d0ff4d748 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/2d.transformation.translate.nonfinite.html @@ -0,0 +1,42 @@ + + +Canvas test: 2d.transformation.translate.nonfinite + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                2d.transformation.translate.nonfinite

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                translate() with Infinity/NaN is ignored

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Actual output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                FAIL (fallback content)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                Expected output:

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/transformations/canvas_transformations_reset_001-ref.html b/testing/web-platform/tests/2dcontext/transformations/canvas_transformations_reset_001-ref.html new file mode 100644 index 000000000..caeea04ce --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/canvas_transformations_reset_001-ref.html @@ -0,0 +1,21 @@ + + + + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + + diff --git a/testing/web-platform/tests/2dcontext/transformations/canvas_transformations_reset_001.html b/testing/web-platform/tests/2dcontext/transformations/canvas_transformations_reset_001.html new file mode 100644 index 000000000..c12acbf6f --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/canvas_transformations_reset_001.html @@ -0,0 +1,22 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/transformations/canvas_transformations_scale_001-ref.htm b/testing/web-platform/tests/2dcontext/transformations/canvas_transformations_scale_001-ref.htm new file mode 100644 index 000000000..1201bcca9 --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/canvas_transformations_scale_001-ref.htm @@ -0,0 +1,11 @@ + + + + HTML5 Canvas Test: scale() transformation + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Description: The scale(x, y) method must add the scaling transformation described by the arguments to the transformation matrix.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  black rectangle
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + + diff --git a/testing/web-platform/tests/2dcontext/transformations/canvas_transformations_scale_001.htm b/testing/web-platform/tests/2dcontext/transformations/canvas_transformations_scale_001.htm new file mode 100644 index 000000000..4c027202e --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/canvas_transformations_scale_001.htm @@ -0,0 +1,30 @@ + + + + HTML5 Canvas Test: scale() transformation + + + + + + + +

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  Description: The scale(x, y) method must add the scaling transformation described by the arguments to the transformation matrix.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  + Browser does not support HTML5 Canvas. + + diff --git a/testing/web-platform/tests/2dcontext/transformations/transform_a.html b/testing/web-platform/tests/2dcontext/transformations/transform_a.html new file mode 100644 index 000000000..8c1f59efd --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/transform_a.html @@ -0,0 +1,22 @@ + + + + + + diff --git a/testing/web-platform/tests/2dcontext/transformations/transform_ref.html b/testing/web-platform/tests/2dcontext/transformations/transform_ref.html new file mode 100644 index 000000000..2a166c36c --- /dev/null +++ b/testing/web-platform/tests/2dcontext/transformations/transform_ref.html @@ -0,0 +1,16 @@ + + + +
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  -- cgit v1.2.3