| <svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="-100 -100 800 600" onload="runRepaintTest();"> |
| <!-- |
| Test for https://bugs.webkit.org/show_bug.cgi?id=76527. |
| Only two green circles should be visible. |
| --> |
| <script xlink:href="../../fast/repaint/resources/repaint.js" type="text/javascript"></script> |
| <defs> |
| <mask id="mask"> |
| <circle cx="100" r="50" fill="white"/> |
| </mask> |
| |
| <clipPath id="clip"> |
| <circle cy="100" r="50"/> |
| <!--Two clip shapes are needed to avoid triggering pathOnlyClipping --> |
| <circle cx="0" cy="0" r="0"/> |
| </clipPath> |
| </defs> |
| |
| <circle cx="100" r="50" fill="red"/> |
| <g mask="url(#mask)"> |
| <rect id="masker" x="-200" y="-200" width="400" height="200" fill="green"/> |
| </g> |
| |
| <circle cy="100" r="50" fill="red"/> |
| <g clip-path="url(#clip)"> |
| <rect id="clipper" x="0" y="-200" width="200" height="400" fill="green"/> |
| </g> |
| |
| <script> |
| function rotate(target, angle) { |
| document.getElementById(target).setAttribute('transform', 'rotate(' + angle + ')'); |
| } |
| |
| function repaintTest() { |
| rotate("masker", 90); |
| rotate("clipper", 90); |
| } |
| </script> |
| </svg> |
| |