Mercurial > hg > NetworkVis
comparison d3s_examples/python-neo4jrestclient/static/platin/lib/excanvas/testcases/overflow.html @ 8:18ef6948d689
new d3s examples
author | Dirk Wintergruen <dwinter@mpiwg-berlin.mpg.de> |
---|---|
date | Thu, 01 Oct 2015 17:17:27 +0200 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
7:45dad9e38c82 | 8:18ef6948d689 |
---|---|
1 <!DOCTYPE html> | |
2 <html> | |
3 <head> | |
4 <title>Overflow Test</title> | |
5 <style> | |
6 | |
7 body { | |
8 text-align: center | |
9 } | |
10 | |
11 </style> | |
12 <!--[if IE]><script type="text/javascript" src="../excanvas.js"></script><![endif]--> | |
13 <script> | |
14 | |
15 window.onload = function() { | |
16 var ctx = document.getElementById('c').getContext('2d'); | |
17 | |
18 ctx.fillStyle = 'blue'; | |
19 ctx.fillRect(-50, -50, 100, 100); | |
20 | |
21 ctx.fillStyle = 'green'; | |
22 ctx.fillRect(50, 50, 100, 100); | |
23 | |
24 ctx.strokeStyle = 'black'; | |
25 ctx.strokeRect(0, 0, 100, 100); | |
26 }; | |
27 | |
28 </script> | |
29 </head> | |
30 <body> | |
31 | |
32 <canvas id=c width=100 height=100></canvas> | |
33 | |
34 <p>This tests if content gets cropped if painting outside the canvas.</p> | |
35 | |
36 </body> | |
37 </html> |