File: fullSector.html

package info (click to toggle)
node-zrender 5.4.1%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 4,544 kB
  • sloc: javascript: 1,259; makefile: 2
file content (35 lines) | stat: -rw-r--r-- 832 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8" />
    <script src="../dist/zrender.js"></script>
</head>
<body>
    <div id="main" style="width:1000px;height:500px;"></div>
    <script type="text/javascript">
        var zr = zrender.init(document.getElementById('main'));

        var curve = new zrender.Sector({
            position: [0, 0],
            scale: [1, 1],
            shape: {
                r: 100,
                r0: 0,
                cx: 100,
                cy: 100,
                startAngle: -1.5707963267948966,
                endAngle: 4.71238898038469
            }
        });

        zr.add(curve);

        curve.animateTo({
            shape: {
                percent: 0
            }
        });
    </script>
    <div id="main" style="width:1000px;height:600px;"></div>
</body>
</html>