2 <!-- This test has a 16px tall div with overflow:hidden set and a child image. When the test loads the div is scrolled out of view.
3 The test is a pass if the image does not appear. -->
4 <body style=
"overflow:hidden">
5 <canvas style=
"position: absolute;"></canvas>
7 document
.querySelector("canvas").getContext("2d");
9 <div style=
"top:0px; height: 16px; overflow: hidden; position: relative;">
10 <img style=
"position: absolute; left: -16px;" id=
"i"></img>
13 <div style=
"height:2000px"></div>
15 var can
= document
.createElement("canvas");
16 can
.width
= can
.height
= 500;
17 var ctx
= can
.getContext("2d");
18 ctx
.fillStyle
= "red";
19 ctx
.fillRect(0, 0, 500, 500);
20 document
.getElementById("i").src
= can
.toDataURL();
21 document
.scrollingElement
.scrollTop
= 50;
22 if (window
.testRunner
)
23 testRunner
.dumpAsTextWithPixelResults();