fix issue #494 & expand xAxisLabelWidth; lots of failing tests
[dygraphs.git] / tests / color-cycle.html
CommitLineData
b5daaaf0
RK
1<!DOCTYPE html>
2<html>
3 <head>
4 <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7; IE=EmulateIE9">
5 <title>color cycles</title>
6 <!--[if IE]>
7 <script type="text/javascript" src="../excanvas.js"></script>
8 <![endif]-->
9 <!--
10 For production (minified) code, use:
11 <script type="text/javascript" src="dygraph-combined.js"></script>
12 -->
13 <script type="text/javascript" src="../dygraph-dev.js"></script>
14
15 </head>
16 <body>
17 <p>Different color cycles</p>
18
19 <div id="blah"></div>
20 <p><b>Colors: </b>
21 <button type=button id=0 onClick="change(this)"> first set</button>
22 <button type=button id=1 onClick="change(this)"> second set</button>
23 <button type=button id=2 onClick="change(this)"> undefined</button>
24 </p>
25
26 <script type="text/javascript">
27 var colorSets = [
28 ['#284785', '#EE1111', '#8AE234'],
29 ['#444444', '#888888', '#DDDDDD'],
30 null
31 ]
32 chart = new Dygraph(document.getElementById("blah"),
33 "X,a,b,c\n" +
34 "10,12345,23456,34567\n" +
35 "11,12345,20123,31345\n",
36 {
37 width: 640,
38 height: 480,
39 colors: colorSets[0]
40 });
41
42 function change(el) {
43 chart.updateOptions({colors: colorSets[el.id]});
44 }
45 </script>
46 </body>
47</html>