Last change
on this file since 28914 was 28914, checked in by ak19, 10 years ago |
Supporting javascript libraries and bespoke code written by Steffan to support the von-sparql user interface
|
File size:
701 bytes
|
Line | |
---|
1 | <!DOCTYPE html>
|
---|
2 | <html>
|
---|
3 | <head>
|
---|
4 | <meta charset="UTF-8">
|
---|
5 | <title>Rectangle Testing</title>
|
---|
6 | <link rel="stylesheet" href="../css/style.css">
|
---|
7 | <script type="text/javascript" src="../../dist/paper.js"></script>
|
---|
8 | <script type="text/paperscript" canvas="canvas">
|
---|
9 | var path = new Path.Rectangle(new Point(50, 50), new Size(100, 50));
|
---|
10 | path.style = {
|
---|
11 | fillColor: 'white',
|
---|
12 | strokeColor: 'black'
|
---|
13 | };
|
---|
14 | var copy = path.clone();
|
---|
15 | copy.strokeColor = 'red';
|
---|
16 | copy.rotate(-45);
|
---|
17 | copy.scale(0.5);
|
---|
18 |
|
---|
19 | document.getElementById('svg').appendChild(project.exportSVG());
|
---|
20 | </script>
|
---|
21 | </head>
|
---|
22 | <body>
|
---|
23 | <canvas id="canvas" width="500" height="500"></canvas>
|
---|
24 | <svg id="svg" width="500" height="500"></svg>
|
---|
25 | </body>
|
---|
26 | </html> |
---|
Note:
See
TracBrowser
for help on using the repository browser.