OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <html> | 2 <html> |
3 <head> | 3 <head> |
4 <script src="../../js/resources/js-test-pre.js"></script> | 4 <script src="../../js/resources/js-test-pre.js"></script> |
5 <script src="../resources/subpixel-utils.js"></script> | 5 <script src="../resources/subpixel-utils.js"></script> |
6 <script> | |
7 if (window.internals) | |
8 window.internals.settings.setCSSExclusionsEnabled(true); | |
9 </script> | |
10 <style> | 6 <style> |
11 #shape-inside { | 7 #shape-inside { |
12 position: relative; | 8 position: relative; |
13 width: 594px; | 9 width: 594px; |
14 height: 500px; | 10 height: 500px; |
15 -webkit-shape-inside: polygon(1.58% 1.42%, 99.42% 1.42%, 98.83% 33.33%,
50.67% 34.08%, 99.50% 66.62%, 98.83% 99.48%, 2.25% 99.07%); | 11 -webkit-shape-inside: polygon(1.58% 1.42%, 99.42% 1.42%, 98.83% 33.33%,
50.67% 34.08%, 99.50% 66.62%, 98.83% 99.48%, 2.25% 99.07%); |
16 font: 14.5px/1 Ahem, sans-serif; | 12 font: 14.5px/1 Ahem, sans-serif; |
17 color: green; | 13 color: green; |
18 } | 14 } |
19 | 15 |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
55 var lineATop = Math.floor(SubPixelLayout.ceilToLayoutUnit(.0142 * 500)); | 51 var lineATop = Math.floor(SubPixelLayout.ceilToLayoutUnit(.0142 * 500)); |
56 | 52 |
57 // Verify that all four one-character lines are vertically adjacent and 15 pix
els high. | 53 // Verify that all four one-character lines are vertically adjacent and 15 pix
els high. |
58 var quiet = true; // PASS output depends on SubPixelLayout.isEnabled() | 54 var quiet = true; // PASS output depends on SubPixelLayout.isEnabled() |
59 shouldBe("shapeInsideRect('a').top", String(lineATop), quiet); | 55 shouldBe("shapeInsideRect('a').top", String(lineATop), quiet); |
60 shouldBe("shapeInsideRect('b').top", String(lineATop + 15), quiet); | 56 shouldBe("shapeInsideRect('b').top", String(lineATop + 15), quiet); |
61 shouldBe("shapeInsideRect('c').top", String(lineATop + 30), quiet); | 57 shouldBe("shapeInsideRect('c').top", String(lineATop + 30), quiet); |
62 shouldBe("shapeInsideRect('d').top", String(lineATop + 45), quiet); | 58 shouldBe("shapeInsideRect('d').top", String(lineATop + 45), quiet); |
63 </script> | 59 </script> |
64 </html> | 60 </html> |
OLD | NEW |