initial commit
[home-automation.git] / RGraph / docs / hbar.html
1 <?php ob_start('ob_gzhandler') ?>
2 <!DOCTYPE html>
3 <html>
4 <head>
5     <meta http-equiv="X-UA-Compatible" content="chrome=1">
6     <!--
7         /**
8         * o------------------------------------------------------------------------------o
9         * | This file is part of the RGraph package - you can learn more at:             |
10         * |                                                                              |
11         * |                          http://www.rgraph.net                               |
12         * |                                                                              |
13         * | This package is licensed under the RGraph license. For all kinds of business |
14         * | purposes there is a small one-time licensing fee to pay and for non          |
15         * | commercial  purposes it is free to use. You can read the full license here:  |
16         * |                                                                              |
17         * |                      http://www.rgraph.net/LICENSE.txt                       |
18         * o------------------------------------------------------------------------------o
19         */
20     -->
21     <title>RGraph: HTML5 canvas graph library - horizontal bar chart documentation</title>
22     
23     <meta name="keywords" content="rgraph html5 canvas graph docs hbar horizontal bar" />
24     <meta name="description" content="RGraph: HTML5 canvas graph software - Documentation about the Horizontal Bar (HBar) chart" />
25
26     <link rel="stylesheet" href="../css/website.css" type="text/css" media="screen" />
27     <link rel="icon" type="image/png" href="../images/favicon.png">
28 </head>
29 <body>
30
31     <!-- Social networking buttons -->
32     <script src="../libraries/RGraph.common.core.js" ></script>
33     
34     <script>
35         function HideTwitterDIV ()
36         {
37             document.getElementById("twitter_div").style.opacity = 0;
38             document.getElementById("twitter_div").style.display = 'none';
39         }
40
41
42         function ShowTwitterDIV (e)
43         {
44             var e   = RGraph.FixEventObject(document.all ? event : e);
45             var div = document.getElementById("twitter_div");
46             var img = document.getElementById("twitter_icon");
47
48             div.style.display = 'block';
49             div.style.left    = (RGraph.getCanvasXY(img)[0] + img.offsetWidth - div.offsetWidth + 110) + 'px';
50             div.style.top     = (RGraph.getCanvasXY(img)[1] - 1) + 'px';
51
52             /**
53             * Fade it in
54             */
55             setTimeout('document.getElementById("twitter_div").style.opacity = 0.2;', 25);
56             setTimeout('document.getElementById("twitter_div").style.opacity = 0.4;', 50);
57             setTimeout('document.getElementById("twitter_div").style.opacity = 0.6;', 100);
58             setTimeout('document.getElementById("twitter_div").style.opacity = 0.8;', 125);
59             setTimeout('document.getElementById("twitter_div").style.opacity = 1.0;', 150);
60
61             e.stopPropagation();
62
63             return false;
64         }
65
66         /**
67         * This code installs the event handler that hides the Twitter DIV
68         */
69         if (RGraph.isIE8()) {
70              window.attachEvent('onload', function () {document.body.attachEvent('onclick', HideTwitterDIV);});
71         } else {
72             window.addEventListener('click', HideTwitterDIV, false);
73         }
74     </script>
75
76     <!-- The twitter DIV --> 
77     <div id="twitter_div" style="position: absolute;top: 0;left: 0;background-color: #eee;border: 2px dashed black;box-shadow: 0 0 15px #aaa;-moz-box-shadow: 0 0 15px #aaa;-webkit-box-shadow: 0 0 15px #aaa;padding: 3px;display: none;opacity: 0;z-index: 99;"> 
78         <a href="http://twitter.com/home/?status=RGraph%3A+HTML5+canvas+graph+library+based+on+the+HTML5+canvas+tag+http%3A%2F%2Fwww.rgraph.net+%23rgraph+%23html5+%23canvas" target="_blank" title="Share on Twitter" rel="nofollow" style="text-decoration: none">Tweet&nbsp;about&nbsp;RGraph</a><br>
79         <a href="http://twitter.com/_rgraph" style="text-decoration: none" rel="nofollow" target="_blank">Follow for HTML5 news</a> 
80     </div>
81
82     <div id="social_icons" class="warning" style="top: 0; left: 5px; position: absolute">
83         <script>
84             // Opera fix
85             if (navigator.userAgent.indexOf('Opera') == -1) {
86               document.getElementById("social_icons").style.position = 'fixed';
87               document.getElementById("twitter_div").style.position = 'fixed';
88     
89             }
90         </script>
91     
92         <b style="display: inline-block; position: relative; top: 1px">Bookmark and share:</b>
93     
94     
95             <div id="social">
96                 <a title="Bookmark with delicious" href="http://delicious.com/save?jump=close&v=4&noui&jump=close&url=http://www.rgraph.net&notes=RGraph%20is%20a%20HTML5%20based%20graph%20library%20supporting%20a%20wide%20range%20of%20different%20graph%20types:Bar,%20Bipolar,%20Donut,%20Funnel,%20Gantt,%20Horizontal%20Bar,%20LED,%20Line,%20Meter,%20Odometer,%20Pie,%20Progress%20Bar,%20Rose,%20RScatter,%20Scatter%20and%20Traditional%20Radar&title=RGraph:%20HTML5%20canvas%20graph%20library%20based%20on%20the%20HTML5%20canvas%20tag" target="_blank">
97                     <img src="../images/delicious.png" alt="Bookmark with delicious" width="22" height="22" border="0" align="absmiddle" /> 
98                 </a> 
99      
100                 <a href="" target="_blank" onmouseover="if (document.getElementById('twitter_div').style.display == 'none') ShowTwitterDIV(event);" onclick="event.stopPropagation(); event.cancelBubble = true; return false">
101                     <img src="../images/twitter.png" id="twitter_icon" alt="tweet this site" width="22" height="22" border="0" align="absmiddle" />
102                 </a>
103     
104     
105 <!--
106                 <a title="Post to Google Buzz!" href="" onclick="window.open('http://www.google.com/buzz/post?url=http://www.rgraph.net&imageurl=http://www.rgraph.net/images/logo.png', 'google_buzz_window', 'width=800,height=400,top=100,left=100'); return false">
107                     <img src="../images/buzz.png" width="22" height="22" alt="Post to Google Buzz!" align="absmiddle" style="position: relative; top: -2px; border: 0" border="0"/>
108                 </a>
109     
110     
111                 <a title="Share RGraph on Facebook" href="" onclick="window.open('http://www.facebook.com/sharer.php?u=http://www.rgraph.net&t=RGraph:%20HTML5%20canvas%20graph%20library', 'facebook_window', 'width=500,height=300,top=100,left=100'); return false">
112                     <img src="../images/facebook.png" width="22" height="22" alt="Post to Facebook" align="absmiddle" style="position: relative; top: -2px; border: 0" border="0"/>
113                 </a>
114     
115                 <a href="mailto:share@friendfeed.com" title="Share on FriendFeed"> 
116                     <img src="../images/friendfeed.png" width="22" height="22" alt="Share on FriendFeed" border="0" align="absmiddle" /> 
117                 </a>
118     
119                 <a href="http://www.stumbleupon.com/submit?url=http://www.rgraph.net" target="_blank" title="Share on StumbleUpon" >
120                     <img src="../images/stumble.png" alt="Stumble! this site" width="22" height="22" border="0" align="absmiddle" /> 
121                 </a>
122 -->
123             </div>
124     </div>
125     <!-- /Social networking buttons -->
126
127     <div id="breadcrumb">
128         <a href="../index.html">RGraph: HTML5 canvas graph library</a>
129         >
130         <a href="index.html">Documentation</a>
131         >
132         Horizontal bar chart
133     </div>
134
135     <h1>RGraph: HTML5 canvas graph library - Horizontal bar chart documentation</h1>
136
137     <script>
138         if (RGraph.isIE8()) {
139             document.write('<div style="background-color: #fee; border: 2px dashed red; padding: 5px"><b>Important</b><br /><br /> Internet Explorer 8 does not natively support the HTML5 canvas tag, so if you want to see the graphs, you can either:<ul><li>Install <a href="http://code.google.com/chrome/chromeframe/">Google Chrome Frame</a></li><li>Use ExCanvas. This is provided in the RGraph Archive.</li><li>Use another browser entirely. Your choices are Firefox 3.5+, Chrome 2+, Safari 4+ or Opera 10.5+. </li></ul> <b>Note:</b> Internet Explorer 9 fully supports the canvas tag. Click <a href="http://groups.google.com/group/rgraph/browse_thread/thread/c5651ff8c56b8f3c#" target="_blank">here</a> to see some screenshots.</div>');
140         }
141     </script>
142
143     <p>
144         The horizontal bar graph is a variation on the bar chart which can be useful when you have larger labels, since you have
145         more space available to you for them.
146     </p>
147     
148     <p>
149         The example file is <a href="../examples/hbar.html">here</a>.
150     </p>
151     
152     <pre class="code">
153 &lt;script&gt;
154     window.onload = function ()
155     {
156         var data = [280,45,133,166,84,259,266,960,219,311];
157     
158         var hbar = new RGraph.HBar('myCanvas', data);
159         hbar.Set('chart.labels', ['Richard', 'Alex', 'Nick', 'Scott', 'Kjnell', 'Doug', 'Charles', 'Michelle', 'Mark', 'Alison']);
160         hbar.Set('chart.gutter', 45);
161         hbar.Set('chart.background.barcolor1', 'rgba(255,255,255,1)');
162         hbar.Set('chart.background.barcolor2', 'rgba(255,255,255,1)');
163         hbar.Set('chart.background.grid', true);
164         hbar.Set('chart.colors', ['rgba(255,0,0,1)']);
165         hbar.Draw();
166     }
167 &lt;/script&gt;
168 </pre>
169
170     <h2>Properties</h2>
171     
172     <p>
173         You can use these properties to control how the bar graph apears. You can set them by using the Set() method. Eg:
174     </p>
175     
176     <p>
177         <b>myHBar.Set('name', 'value');</b>
178     </p>
179
180     <ul>
181         <li><a href="#margins">Margins</a></li>
182         <li><a href="#colors">Colors</a></li>
183         <li><a href="#background">Background</a></li>
184         <li><a href="#labels and text">Labels and text</a></li>
185         <li><a href="#titles">Titles</a></li>
186         <li><a href="#scale and axes">Scale and axes</a></li>
187         <li><a href="#miscellaneous">Miscellaneous</a></li>
188         <li><a href="#shadow">Shadow</a></li>
189         <li><a href="#key">Key</a></li>
190         <li><a href="#interactive features">Interactive features</a></li>
191         <li><a href="#zoom">Zoom</a></li>
192     </ul>
193
194
195 <a name="margins"></a>
196 <h3 style="border: 1px solid #aaa; background-color: #eee; font-style: italic; padding: 5px; -moz-border-radius: 10px; -webkit-border-radius: 10px; border-radius: 10px">Margins</h3>            <a name="chart.gutter"></a>
197 <b>chart.gutter</b><br />
198             The gutter of the graph. This is the area outside of the X and Y axis - where the labels go. If you're short on space for your labels, try increasing this. <br /><i>Default: 25</i><br /><br />
199 <a name="colors"></a>
200 <h3 style="border: 1px solid #aaa; background-color: #eee; font-style: italic; padding: 5px; -moz-border-radius: 10px; -webkit-border-radius: 10px; border-radius: 10px">Colors</h3>            <a name="chart.colors"></a>
201 <b>chart.colors</b><br />
202             An array of the colors of the actual bars. <br /><i>Default: An array - ['rgb(0,0,255)', '#0f0', '#00f', '#ff0', '#0ff', '#0f0']</i><br /><br />
203 <a name="background"></a>
204 <h3 style="border: 1px solid #aaa; background-color: #eee; font-style: italic; padding: 5px; -moz-border-radius: 10px; -webkit-border-radius: 10px; border-radius: 10px">Background</h3>            <a name="chart.background.barcolor1"></a>
205 <b>chart.background.barcolor1</b><br />
206             The color of the background bars, (1 of 2). <br /><i>Default: white</i><br /><br />
207             <a name="chart.background.barcolor2"></a>
208 <b>chart.background.barcolor2</b><br />
209             The color of the background bars, (2 of 2). <br /><i>Default: white</i><br /><br />
210             <a name="chart.background.grid"></a>
211 <b>chart.background.grid</b><br />
212             Whether to show the background grid or not. <br /><i>Default: true</i><br /><br />
213             <a name="chart.background.grid.color"></a>
214 <b>chart.background.grid.color</b><br />
215             The color of the background grid. <br /><i>Default: #ddd</i><br /><br />
216             <a name="chart.background.grid.hsize"></a>
217 <b>chart.background.grid.hsize</b><br />
218             The horizontal background grid size. <br /><i>Default: 40</i><br /><br />
219             <a name="chart.background.grid.vsize"></a>
220 <b>chart.background.grid.vsize</b><br />
221             The vertical background grid size. <br /><i>Default: 18</i><br /><br />
222             <a name="chart.background.grid.width"></a>
223 <b>chart.background.grid.width</b><br />
224             The width that the background grid lines are. Decimals (eg 0.5) are permitted.<br /><i>Default: 0.5</i><br /><br />
225             <a name="chart.background.grid.border"></a>
226 <b>chart.background.grid.border</b><br />
227             Determines whether a border line is drawn around the grid.<br /><i>Default: true</i><br /><br />
228             <a name="chart.background.grid.hlines"></a>
229 <b>chart.background.grid.hlines</b><br />
230             Determines whether to draw the horizontal grid lines.<br /><i>Default: true</i><br /><br />
231             <a name="chart.background.grid.vlines"></a>
232 <b>chart.background.grid.vlines</b><br />
233             Determines whether to draw the vertical grid lines.<br /><i>Default: true</i><br /><br />
234             <a name="chart.background.grid.autofit"></a>
235 <b>chart.background.grid.autofit</b><br />
236             Instead of specifying a pixel width/height for the background grid, you can use autofit and specify how many horizontal and vertical lines you want.<br /><i>Default: false</i><br /><br />
237             <a name="chart.background.grid.autofit.numhlines"></a>
238 <b>chart.background.grid.autofit.numhlines</b><br />
239             When using autofit this allows you to specify how many horizontal grid lines you want. <br /><i>Default: 14</i><br /><br />
240             <a name="chart.background.grid.autofit.numvlines"></a>
241 <b>chart.background.grid.autofit.numvlines</b><br />
242             When using autofit this allows you to specify how many vertical grid lines you want. <br /><i>Default: 20</i><br /><br />
243 <a name="labels and text"></a>
244 <h3 style="border: 1px solid #aaa; background-color: #eee; font-style: italic; padding: 5px; -moz-border-radius: 10px; -webkit-border-radius: 10px; border-radius: 10px">Labels and text</h3>            <a name="chart.labels"></a>
245 <b>chart.labels</b><br />
246             An array of the labels to be used on the graph. <br /><i>Default: An empty array</i><br /><br />
247             
248             <a name="chart.labels.above"></a>
249             <b>chart.labels.above</b><br />
250             This is a boolean which if true, will cause labels to be shown to the right of the bars. (It's called "above"
251             for API compatibility).<br />
252             <i>Default: false</i><br /><br />
253             
254             <a name="chart.labels.above.decimals"></a>
255             <b>chart.labels.above.decimals</b><br />
256             This is a number which controls how many decimals are shown. It defaults to 0, and since it was added (4th December 2010)
257             you may need to set this, otherwise no decimals will be shown.<br />
258             <i>Default: 0</i><br /><br />
259             
260             <a name="chart.text.font"></a>
261 <b>chart.text.font</b><br />
262             The font used to render the text.<br /><i>Default: Verdana</i><br /><br />
263             <a name="chart.text.color"></a>
264 <b>chart.text.color</b><br />
265             The color of the labels. <br /><i>Default: black</i><br /><br />
266             <a name="chart.text.size"></a>
267 <b>chart.text.size</b><br />
268             The size (in points) of the labels. <br /><i>Default: 10</i><br /><br />
269 <a name="titles"></a>
270 <h3 style="border: 1px solid #aaa; background-color: #eee; font-style: italic; padding: 5px; -moz-border-radius: 10px; -webkit-border-radius: 10px; border-radius: 10px">Titles</h3>            <a name="chart.title"></a>
271 <b>chart.title</b><br />
272             The title of the graph, if any. <br /><i>Default: null</i><br /><br />
273
274 <a name="chart.title.background"></a>
275 <b>chart.title.background</b><br />
276 The background color (if any) for the title.<br />
277 <i>Default: null</i><br /><br />
278
279             <a name="chart.title.hpos"></a>
280 <b>chart.title.hpos</b><br />
281             This allows you to completely override the horizontal positioning of the title. It should be a number between 0 and 1, and is multiplied with the whole width of the canvas and then used as the horizontal position. <br /><i>Default: null</i><br /><br />
282             <a name="chart.title.vpos"></a>
283 <b>chart.title.vpos</b><br />
284             This allows you to completely override the vertical positioning of the title. It should be a number between 0 and 1, and is multiplied with the gutter and then used as the vertical position. It can be useful if you need to have a large gutter.<br /><i>Default: null</i><br /><br />
285             <a name="chart.title.xaxis"></a>
286 <b>chart.title.xaxis</b><br />
287             This allows to specify a title for the X axis.<br /><i>Default: none</i><br /><br />
288             <a name="chart.title.yaxis"></a>
289 <b>chart.title.yaxis</b><br />
290             This allows to specify a title for the Y axis.<br /><i>Default: none</i><br /><br />
291             <a name="chart.title.xaxis.pos"></a>
292 <b>chart.title.xaxis.pos</b><br />
293             This is multiplied with the gutter to give the position of the X axis title.<br /><i>Default: 0.25</i><br /><br />
294             <a name="chart.title.yaxis.pos"></a>
295 <b>chart.title.yaxis.pos</b><br />
296             This is multiplied with the gutter to give the position of the Y axis title.<br /><i>Default: 0.5</i><br /><br />
297             <a name="chart.title.color"></a>
298 <b>chart.title.color</b><br />
299             The color of the title.<br /> <i>Default: black</i><br /><br />
300 <a name="scale and axes"></a>
301 <h3 style="border: 1px solid #aaa; background-color: #eee; font-style: italic; padding: 5px; -moz-border-radius: 10px; -webkit-border-radius: 10px; border-radius: 10px">Scale and axes</h3>            <a name="chart.scale.point"></a>
302 <b>chart.scale.point</b><br />
303             The character used as the decimal point.<br /><i>Default: .</i><br /><br />
304             <a name="chart.scale.thousand"></a>
305 <b>chart.scale.thousand</b><br />
306             The character used as the thousand separator<br /><i>Default: ,</i><br /><br />
307
308             <a name="chart.scale.round"></a>
309             <b>chart.scale.round</b><br />
310             Whether to round the maximum scale value up or not. This will produce slightly better scales in some instances.<br />
311             <i>Default: null</i><br /><br />
312
313             <a name="chart.xmax"></a>
314 <b>chart.xmax</b><br />
315             (Optional) An optional max figure for the X scale.<br /> <i>Default: none (one is calculated)</i><br /><br />
316             <a name="chart.yaxispos"></a>
317 <b>chart.yaxispos</b><br />
318             The position of the Y axis. Works with regular and grouped charts. Can be either <i>center</i> or <i>left</i>.<br /> <i>Default: left</i><br /><br />
319             <a name="chart.axis.color"></a>
320 <b>chart.axis.color</b><br />
321             The color of the axes.<br /> <i>Default: black</i><br /><br />
322             <a name="chart.units.pre"></a>
323 <b>chart.units.pre</b><br />
324             The units that the X axis is measured in. This string is displayed BEFORE the actual number, allowing you to specify values such as "$50".<br /><i>Default: none</i><br /><br />
325             <a name="chart.units.post"></a>
326 <b>chart.units.post</b><br />
327             The units that the X axis is measured in. This string is displayed AFTER the actual number, allowing you to specify values such as "50ms".<br /><i>Default: none</i><br /><br />
328             <a name="chart.units.ingraph"></a>
329 <b>chart.units.ingraph</b><br />
330             If your units are long, setting this stipulates them to be used for ingraph labels only.<br /><i>Default: false</i><br /><br />
331 <a name="miscellaneous"></a>
332 <h3 style="border: 1px solid #aaa; background-color: #eee; font-style: italic; padding: 5px; -moz-border-radius: 10px; -webkit-border-radius: 10px; border-radius: 10px">Miscellaneous</h3>            <a name="chart.grouping"></a>
333 <b>chart.grouping</b><br />
334             How the bars are grouped, and it should be one of: <b>grouped</b> or <b>stacked</b><br /><i>Default: grouped</i><br /><br />
335             <a name="chart.vmargin"></a>
336 <b>chart.vmargin</b><br />
337             The vertical margin that is applied to each individual bar.<br /><i>Default: 3</i><br /><br />
338             <a name="chart.strokestyle"></a>
339 <b>chart.strokestyle</b><br />
340             The color of the outlines of the bars.<br /><i>Default: black</i><br /><br />
341 <a name="shadow"></a>
342 <h3 style="border: 1px solid #aaa; background-color: #eee; font-style: italic; padding: 5px; -moz-border-radius: 10px; -webkit-border-radius: 10px; border-radius: 10px">Shadow</h3>            <a name="chart.shadow"></a>
343 <b>chart.shadow</b><br />
344             Whether a small drop shadow is applied. <br /><i>Default: false</i><br /><br />
345             <a name="chart.shadow.color"></a>
346 <b>chart.shadow.color</b><br />
347             The color of the shadow. <br /><i>Default: #666</i><br /><br />
348             <a name="chart.shadow.offsetx"></a>
349 <b>chart.shadow.offsetx</b><br />
350             The X offset of the shadow. <br /><i>Default: 3</i><br /><br />
351             <a name="chart.shadow.offsety"></a>
352 <b>chart.shadow.offsety</b><br />
353             The Y offset of the shadow. <br /><i>Default: 3</i><br /><br />
354             <a name="chart.shadow.blur"></a>
355 <b>chart.shadow.blur</b><br />
356             The severity of the shadow blurring effect. <br /><i>Default: 3</i><br /><br />
357
358
359
360             <a name="key"></a>
361             <h3 style="border: 1px solid #aaa; background-color: #eee; font-style: italic; padding: 5px; -moz-border-radius: 10px; -webkit-border-radius: 10px; border-radius: 10px">Key</h3>
362             
363             <a name="chart.key"></a>
364             <b>chart.key</b><br />
365             An array of key information. <br />
366             <i>Default: [] (An empty array)</i><br /><br />
367
368             <a name="chart.key.background"></a>
369             <b>chart.key.background</b><br />
370             The color of the key background. Typically white, you could set this to something like rgba(255,255,255,0.7) to allow people to see things behind it.<br>
371             <i>Default: white</i><br /><br />
372             
373             <a name="chart.key.position"></a>
374             <b>chart.key.position</b><br />
375             Determines the position of the key.Either <b>graph</b> (default), or <b>gutter</b>.<br />
376             <i>Default: graph</i><br /><br />
377             
378             <b>chart.key.position.x</b><br />
379             This allows you to specify a specific X coordinate for the key.<br />
380             <i>Default: null</i><br /><br />
381             
382             <b>chart.key.position.y</b><br />
383             This allows you to specify a specific Y coordinate for the key.<br />
384             <i>Default: null</i><br /><br />
385             
386             <b>chart.key.position.gutter.boxed</b><br />
387             If you have the key in gutter mode (ie horizontal), this allows you to give a background color.<br />
388             <i>Default: true</i><br /><br />
389             
390             <a name="chart.key.shadow"></a>
391             <b>chart.key.shadow</b><br />
392             Whether a small drop shadow is applied to the key.<br />
393             <i>Default: false</i><br /><br />
394
395             <a name="chart.key.shadow.color"></a>
396             <b>chart.key.shadow.color</b><br />
397             The color of the shadow.<br />
398             <i>Default: #666</i><br /><br />
399
400             <a name="chart.key.shadow.blur"></a>
401             <b>chart.key.shadow.blur</b><br />
402             The extent of the blurring effect used on the shadow.<br />
403             <i>Default: 3</i><br /><br />
404
405             <a name="chart.key.shadow.offsetx"></a>
406             <b>chart.key.shadow.offsetx</b><br />
407             The X offset of the shadow.<br />
408             <i>Default: 2</i><br /><br />
409
410             <a name="chart.key.shadow.offsety"></a>
411             <b>chart.key.shadow.offsety</b><br />
412             The Y offset of the shadow.<br />
413             <i>Default: 2</i><br /><br />
414
415             <b>chart.key.rounded</b><br />
416             This controls whether the corners of the key (in graph mode) are curved. If the key is gutter mode, this has no effect.<br />
417             <i>Default: false</i><br /><br />
418             
419             <b>chart.key.color.shape</b><br />
420             This can be <i>square</i>, <i>circle</i> or <i>line</i> and controls how the color indicators in the key appear.<br />
421             <i>Default: square</i><br /><br />
422
423
424 <a name="interactive features"></a>
425 <h3 style="border: 1px solid #aaa; background-color: #eee; font-style: italic; padding: 5px; -moz-border-radius: 10px; -webkit-border-radius: 10px; border-radius: 10px">Interactive features</h3>            <a name="chart.contextmenu"></a>
426 <b>chart.contextmenu</b><br />
427             An array of context menu items. You cannot have context menus AND tooltips, only one or the other. More information on context menus is <a href="context.html">here</a>.<br /><i>Default: [] (An empty array)</i><br /><br />
428             <a name="chart.tooltips"></a>
429 <b>chart.tooltips</b><br />
430             An array of tooltips for the chart.<br /><i>Default: An empty array</i><br /><br />
431             <a name="chart.tooltips.effect"></a>
432 <b>chart.tooltips.effect</b><br />
433             The visual effect used when showing tooltips. Can be either <i>fade</i> or <i>expand</i>.<br /><i>Default: fade</i><br /><br />
434             <a name="chart.tooltips.css.class"></a>
435 <b>chart.tooltips.css.class</b><br />
436             This is the name of the CSS class the graph uses.<br /><i>Default: RGraph_tooltip</i><br /><br />
437             <a name="chart.tooltips.override"></a>
438 <b>chart.tooltips.override</b><br />
439             If you wish to handle showing tooltips yourself, this should be a function object which does just that. There's more information on the <a href="tooltips.html">tooltips documentation page</a><br /><i>Default: null</i><br /><br />
440             <a name="chart.annotatable"></a>
441 <b>chart.annotatable</b><br />
442             Whether annotations are enabled for the chart (ie you can draw on the chart interactively.<br /><i>Default: false</i><br /><br />
443             <a name="chart.annotate.color"></a>
444 <b>chart.annotate.color</b><br />
445             If you do not allow the use of the palette, then this will be the only colour allowed for annotations.<br /><i>Default: black</i><br /><br />
446             <a name="chart.resizable"></a>
447 <b>chart.resizable</b><br />
448             Defaulting to false, this determines whether your graph will be resizable. Because of the numerous event handlers this has to install code on, This feature is unlikely to work with other dynamic features (the context menu is fine however).<br /><i>Default: false</i><br /><br />
449 <a name="zoom"></a>
450 <h3 style="border: 1px solid #aaa; background-color: #eee; font-style: italic; padding: 5px; -moz-border-radius: 10px; -webkit-border-radius: 10px; border-radius: 10px">Zoom</h3>            <a name="chart.zoom.mode"></a>
451 <b>chart.zoom.mode</b><br />
452             Can be used to control whether the zoom is in thumbnail or canvas mode. Possible values are: <i>thumbnail</i> and <i>canvas</i>.<br /><i>Default: canvas</i><br /><br />
453             <a name="chart.zoom.factor"></a>
454 <b>chart.zoom.factor</b><br />
455             This is the factor that the graph will be zoomed by (bigger values means more zoom)<br /><i>Default: 1.5</i><br /><br />
456             <a name="chart.zoom.fade.in"></a>
457 <b>chart.zoom.fade.in</b><br />
458             Whether the zoomed canvas fades in or not. This also can be used to control the fade in for the zoom in thumbnail mode.<br /><i>Default: true</i><br /><br />
459             <a name="chart.zoom.fade.out"></a>
460 <b>chart.zoom.fade.out</b><br />
461             Whether the zoomed canvas fades out or not. This also can be used to control the fade in for the zoom in thumbnail mode.<br /><i>Default: true</i><br /><br />
462             <a name="chart.zoom.hdir"></a>
463 <b>chart.zoom.hdir</b><br />
464             The horizontal direction of the zoom. Possible values are: <i>left</i>, <i>center</i>, <i>right</i><br /><i>Default: right</i><br /><br />
465             <a name="chart.zoom.vdir"></a>
466 <b>chart.zoom.vdir</b><br />
467             The vertical direction of the zoom. Possible values are: <i>up</i>, <i>center</i>, <i>down</i><br /><i>Default: down</i><br /><br />
468             <a name="chart.zoom.delay"></a>
469 <b>chart.zoom.delay</b><br />
470             The delay (in milliseconds) between frames.<br /><i>Default: 50</i><br /><br />
471             <a name="chart.zoom.frames"></a>
472 <b>chart.zoom.frames</b><br />
473             The number of frames in the zoom animation.<br /><i>Default: 10</i><br /><br />
474             <a name="chart.zoom.shadow"></a>
475 <b>chart.zoom.shadow</b><br />
476             Whether or not the zoomed canvas has a shadow or not.<br /><i>Default: true</i><br /><br />
477             <a name="chart.zoom.thumbnail.width"></a>
478 <b>chart.zoom.thumbnail.width</b><br />
479             When the zoom is in thumbnail mode, this is the width (in pixels) of the thumbnail.<br /><i>Default: 75</i><br /><br />
480             <a name="chart.zoom.thumbnail.height"></a>
481 <b>chart.zoom.thumbnail.height</b><br />
482             When the zoom is in thumbnail mode, this is the height (in pixels) of the thumbnail.<br /><i>Default: 75</i><br /><br />
483             <a name="chart.zoom.background"></a>
484 <b>chart.zoom.background</b><br />
485             Defaulting to true, this determines whether the zoom has a dark, semi-opaque background that covers the entire web page.<br /><i>Default: true</i><br /><br />
486 </div><!-- /DOCS --><br /><br />
487     
488 </body>
489 </html>