Debian Codegraph @

dojox/charting/tests/BidiSupport/mirror_axes.html

raw symbols SCIP
1 <!--[if IE 7]>
2 <!DOCTYPE>
3 <html lang="en">
4 <head>
5 <![endif]-->
6 <!--[if IE 8]>
7 <!DOCTYPE>
8 <html lang="en">
9 <head>
10 <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7"/>
11 <![endif]-->
12 <![if gte IE 9]>
13 <!DOCTYPE HTML>
14 <html lang="en">
15 <head>
16 <![endif]>
17 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
18 <title>Testing Axes</title>
19 <style type="text/css">
20 @import "../../../../dojo/resources/dojo.css";
21 @import "../../../../dijit/tests/css/dijitTests.css";
22 </style>
23 <script src="../../../../dojo/dojo.js" data-dojo-config="isDebug: true, has:{'dojo-bidi': true}"></script>
24 <script>
25
26 dojo.require("dojox.charting.Chart");
27 dojo.require("dojox.charting.axis2d.Invisible");
28 dojo.require("dojox.charting.axis2d.Default");
29 dojo.require("dojox.charting.plot2d.Markers");
30 dojo.require("dojox.charting.themes.ThreeD");
31
32 makeObjects = function(){
33 dojo.query("button").style("disabled", true);
34
35 var customTheme = dojox.charting.themes.ThreeD.clone();
36 customTheme.plotarea.fill = "#fed";
37
38 var chart1 = new dojox.charting.Chart("test1").
39 setTheme(customTheme).
40 addAxis("x", {fixLower: "major", fixUpper: "major", natural: true, includeZero: true, majorTick: { length: -10}}).
41 addAxis("y", {vertical: true, fixLower: "major", fixUpper: "major", natural: true, includeZero: true}).
42 addPlot("default", {type: "Markers"}).
43 addSeries("Series A", [{x: 1, y: 1}, {x: 2, y: 2}, {x: 3, y: 1}]).
44 addSeries("Series B", [{x: 3, y: 2}, {x: 4, y: 3}, {x: 5, y: 2}]).
45 addSeries("Series C", [{x: 5, y: 3}, {x: 6, y: 4}, {x: 7, y: 3}]).
46 setDir("rtl").
47 render();
48
49 var chart2 = new dojox.charting.Chart("test2").
50 setTheme(customTheme).
51 addAxis("x", {fixLower: "major", fixUpper: "major", natural: true, includeZero: true, majorTick: { length: 10}}).
52 addAxis("y", {vertical: true, fixLower: "major", fixUpper: "major", natural: true, includeZero: true, majorTick: {length: -5}, minorTicks: false}).
53 addPlot("p1", {type: "Markers"}).
54 addPlot("p2", {type: "Markers"}).
55 addPlot("p3", {type: "Markers"}).
56 addSeries("Series A", [{x: 1, y: 1}, {x: 2, y: 2}, {x: 3, y: 1}], {plot: "p1"}).
57 addSeries("Series B", [{x: 3, y: 2}, {x: 4, y: 3}, {x: 5, y: 2}], {plot: "p2"}).
58 addSeries("Series C", [{x: 5, y: 3}, {x: 6, y: 4}, {x: 7, y: 3}], {plot: "p3"}).
59 setDir("rtl").
60 render();
61
62 var chart3 = new dojox.charting.Chart("test3").
63 setTheme(customTheme).
64 addAxis("x", {type: "Invisible", fixLower: "major", fixUpper: "major", natural: true, includeZero: true}).
65 addAxis("y", {type: "Invisible",vertical: true, fixLower: "major", fixUpper: "major", natural: true, includeZero: true}).
66 addPlot("default", {type: "Markers"}).
67 addSeries("Series A", [{x: 1, y: 1}, {x: 2, y: 2}, {x: 3, y: 1}]).
68 addSeries("Series B", [{x: 3, y: 2}, {x: 4, y: 3}, {x: 5, y: 2}]).
69 addSeries("Series C", [{x: 5, y: 3}, {x: 6, y: 4}, {x: 7, y: 3}]).
70 setDir("rtl").
71 render();
72
73 var chart4 = new dojox.charting.Chart("test4").
74 setTheme(customTheme).
75 addPlot("default", {type: "Markers"}).
76 addSeries("Series A", [{x: 1, y: 1}, {x: 2, y: 2}, {x: 3, y: 1}]).
77 addSeries("Series B", [{x: 3, y: 2}, {x: 4, y: 3}, {x: 5, y: 2}]).
78 addSeries("Series C", [{x: 5, y: 3}, {x: 6, y: 4}, {x: 7, y: 3}]).
79 setDir("rtl").
80 render();
81
82 var chart4 = new dojox.charting.Chart("test5", {title: "Chart Title", titleAlign: "edge"}).
83 setTheme(customTheme).
84 addAxis("x", {fixLower: "major", fixUpper: "major", natural: true, includeZero: true, majorTick: { length: -10}}).
85 addAxis("y", {vertical: true, fixLower: "major", fixUpper: "major", natural: true, includeZero: true}).
86 addPlot("default", {type: "Markers"}).
87 addSeries("Series A", [{x: 1, y: 1}, {x: 2, y: 2}, {x: 3, y: 1}]).
88 addSeries("Series B", [{x: 3, y: 2}, {x: 4, y: 3}, {x: 5, y: 2}]).
89 addSeries("Series C", [{x: 5, y: 3}, {x: 6, y: 4}, {x: 7, y: 3}]).
90 setDir("rtl").
91 render();
92 };
93
94 dojo.ready(makeObjects);
95
96 </script>
97 </head>
98 <body>
99 <h1>Testing Axes</h1>
100 <!--<p><button onclick="makeObjects();">Go</button></p>-->
101 <p>1: Shared axes and three series</p>
102 <div id="test1" style="width: 200px; height: 200px;"></div>
103 <p>2: Shared axes and three plots.</p>
104 <div id="test2" style="width: 200px; height: 200px;"></div>
105 <p>3: Like #1 but invisible axes.</p>
106 <div id="test3" style="width: 200px; height: 200px;"></div>
107 <p>4: Like #1 but no axes.</p>
108 <div id="test4" style="width: 200px; height: 200px;"></div>
109 <p>4: Like #1 but with the title aligned to the axis edge.</p>
110 <div id="test5" style="width: 200px; height: 200px;"></div>
111 <p>That's all Folks!</p>
112 </body>
113 </html>