HTMLcopy
1
<div id="container"></div>
CSScopy
6
1
html, body, #container {
2
width: 100%;
3
height: 100%;
4
margin: 0;
5
padding: 0;
6
}
JavaScriptcopy
x
1
var stage = acgraph.create('container');
2
3
var blueCircle = stage.circle(170, 100, 100);
4
blueCircle.fill('#90CAF9');
5
6
var rectangle = stage.rect(120, 50, 100, 100);
7
rectangle.fill('#90CAF9');
8
9
// Sets rotation.
10
rectangle.setRotation(20, 120, 50);
11
12
rectangle.rotate(30, 120, 50);