OLD | NEW |
1 <body> | 1 <body> |
2 <style type="text/css"> | 2 <style type="text/css"> |
3 canvas { border: 1px solid black; } | 3 canvas { border: 1px solid black; } |
4 </style> | 4 </style> |
5 | 5 |
6 Each square canvas should contain a colored gradient bordered by a narrow white
margin and a black line. | 6 Each square canvas should contain a colored gradient bordered by a narrow white
margin and a black line. |
7 The column on the left contains linear gradients, the column on the right radial
gradients.<br> | 7 The column on the left contains linear gradients, the column on the right radial
gradients.<br> |
8 | 8 |
9 <script> | 9 <script> |
10 if (window.testRunner) | 10 if (window.testRunner) |
11 testRunner.dumpAsText(true); | 11 testRunner.dumpAsTextWithPixelResults(); |
12 | 12 |
13 var counter = 1; | 13 var counter = 1; |
14 function Test(description, gradient) { | 14 function Test(description, gradient) { |
15 // Create canvas elements | 15 // Create canvas elements |
16 var lin = document.createElement('canvas'); | 16 var lin = document.createElement('canvas'); |
17 lin.setAttribute('id', 'canvas' + counter + 'lin'); | 17 lin.setAttribute('id', 'canvas' + counter + 'lin'); |
18 lin.setAttribute('height', 50); | 18 lin.setAttribute('height', 50); |
19 lin.setAttribute('width', 50); | 19 lin.setAttribute('width', 50); |
20 var rad = document.createElement('canvas'); | 20 var rad = document.createElement('canvas'); |
21 rad.setAttribute('id', 'canvas' + counter + 'rad'); | 21 rad.setAttribute('id', 'canvas' + counter + 'rad'); |
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
99 // Unsorted stops | 99 // Unsorted stops |
100 Test('Blue to white, red to yellow (same as previous)', | 100 Test('Blue to white, red to yellow (same as previous)', |
101 new Array(0.5, '#fff', | 101 new Array(0.5, '#fff', |
102 0.5, '#aaa', | 102 0.5, '#aaa', |
103 1, '#ff0', | 103 1, '#ff0', |
104 0.5, '#abc', | 104 0.5, '#abc', |
105 0.5, '#f00', | 105 0.5, '#f00', |
106 0, '#00f')); | 106 0, '#00f')); |
107 </script> | 107 </script> |
108 </body> | 108 </body> |
OLD | NEW |