| <!DOCTYPE html> |
| <script src="../../fast/repaint/resources/text-based-repaint.js"></script> |
| <script> |
| function repaintTest() { |
| document.getElementsByTagName('rect')[0].setAttribute('y', '50'); |
| }; |
| |
| window.onload = function() { |
| // Change parent transform and position at the same time, to check if the next |
| // position change in repaintTest() can repaint the old location correctly. |
| document.getElementsByTagName('g')[0].setAttribute('transform', 'scale(2)'); |
| document.getElementsByTagName('rect')[0].setAttribute('x', '50'); |
| runRepaintTest(); |
| } |
| |
| </script> |
| <svg width="400" height="400"> |
| <g> |
| <rect width="50" height="50" fill="green"/> |
| </g> |
| </svg> |