<!-- saved from url=(0026)http://www.naturaldocs.org -->
<divid=Content><divclass="CClass"><divclass=CTopicid=MainTopic><divclass="CTitle logo"><divclass="nav"><aclass="nav"href="../../../index.php"><span>></span>Home</a><aclass="nav"href="../../../tests/"><span>></span>Examples</a><aclass="nav"href="../../../docs/"><span>></span>Docs</a><aclass="nav"href="http://bitbucket.org/cleonello/jqplot/downloads/"><span>></span>Download</a><aclass="nav"href="../../../info.php"><span>></span>Info</a><aclass="nav"href="../../../donate.php"><span>></span>Donate</a></div><aname="$.jqplot.CanvasAxisTickRenderer"></a>$.jqplot.<wbr>CanvasAxisTickRenderer</div><divclass=CBody><p>Renderer to draw axis ticks with a canvas element to support advanced featrues such as rotated text. This renderer uses a separate rendering engine to draw the text on the canvas. Two modes of rendering the text are available. If the browser has native font support for canvas fonts (currently Mozila 3.5 and Safari 4), you can enable text rendering with the canvas fillText method. You do so by setting the “enableFontSupport” option to true.</p><p>Browsers lacking native font support will have the text drawn on the canvas using the Hershey font metrics. Even if the “enableFontSupport” option is true non-supporting browsers will still render with the Hershey font.</p><!--START_ND_SUMMARY--><divclass=Summary><divclass=STitle>Summary</div><divclass=SBorder><tableborder=0cellspacing=0cellpadding=0class=STable><trclass="SMain"><tdclass=SEntry><ahref="#$.jqplot.CanvasAxisTickRenderer">$.jqplot.<wbr>CanvasAxisTickRenderer</a></td><tdclass=SDescription>Renderer to draw axis ticks with a canvas element to support advanced featrues such as rotated text. </td></tr><trclass="SGroup SIndent1"><tdclass=SEntry><ahref="#$.jqplot.CanvasAxisTickRenderer.Properties">Properties</a></td><tdclass=SDescription></td></tr><trclass="SProperty SIndent2 SMarked"><tdclass=SEntry><ahref="#$.jqplot.CanvasAxisTickRenderer.mark"id=link1onMouseOver="ShowTip(event, 'tt1', 'link1')"onMouseOut="HideTip('tt1')">mark</a></td><tdclass=SDescription>tick mark on the axis. </td></tr><trclass="SProperty SIndent2"><tdclass=SEntry><ahref="#$.jqplot.CanvasAxisTickRenderer.showMark"id=link2onMouseOver="ShowTip(event, 'tt2', 'link2')"onMouseOut="HideTip('tt2')">showMark</a></td><tdclass=SDescription>wether or not to show the mark on the axis.</td></tr><trclass="SProperty SIndent2 SMarked"><tdclass=SEntry><ahref="#$.jqplot.CanvasAxisTickRenderer.showGridline"id=link3onMouseOver="ShowTip(event, 'tt3', 'link3')"onMouseOut="HideTip('tt3')">showGridline</a></td><tdclass=SDescription>wether or not to draw the gridline on the grid at this tick.</td></tr><trclass="SProperty SIndent2"><tdclass=SEntry><ahref="#$.jqplot.CanvasAxisTickRenderer.isMinorTick"id=link4onMouseOver="ShowTip(event, 'tt4', 'link4')"onMouseOut="HideTip('tt4')">isMinorTick</a></td><tdclass=SDescription>if this is a minor tick.</td></tr><trclass="SProperty SIndent2 SMarked"><tdclass=SEntry><ahref="#$.jqplot.CanvasAxisTickRenderer.angle"id=link5onMouseOver="ShowTip(event, 'tt5', 'link5')"onMouseOut="HideTip('tt5')">angle</a></td><tdclass=SDescription>angle of text, measured clockwise from x axis.</td></tr><trclass="SProperty SIndent2"><tdclass=SEntry><ahref="#$.jqplot.CanvasAxisTickRenderer.markSize"id=link6onMouseOver="ShowTip(event, 'tt6', 'link6')"onMouseOut="HideTip('tt6')">markSize</a></td><tdclass=SDescription>Length of the tick marks in pixels. </td></tr><trclass="SProperty SIndent2 SMarked"><tdclass=SEntry><ahref="#$.jqplot.CanvasAxisTickRenderer.show"id=link7onMouseOver="ShowTip(event, 'tt7', 'link7')"onMouseOut="HideTip('tt7')">show</a></td><tdclass=SDescription>wether or not to show the tick (mark and label).</td></tr><trclass="SProperty SIndent2"><tdclass=SEntry><ahref="#$.jqplot.CanvasAxisTickRenderer.showLabel"id=link8onMouseOver="ShowTip(event, 'tt8', 'link8')"onMouseOut="HideTip('tt8')">showLabel</a></td><tdclass=SDescriptio
<divclass="CProperty"><divclass=CTopic><h3class=CTitle><aname="$.jqplot.CanvasAxisTickRenderer.mark"></a>mark</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.mark = 'outside'</td></tr></table></blockquote><p>tick mark on the axis. One of ‘inside’, ‘outside’, ‘cross’, ‘’ or null.</p></div></div></div>
<divclass="CProperty"><divclass=CTopic><h3class=CTitle><aname="$.jqplot.CanvasAxisTickRenderer.showMark"></a>showMark</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.showMark = true</td></tr></table></blockquote><p>wether or not to show the mark on the axis.</p></div></div></div>
<divclass="CProperty"><divclass=CTopic><h3class=CTitle><aname="$.jqplot.CanvasAxisTickRenderer.showGridline"></a>showGridline</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.showGridline = true</td></tr></table></blockquote><p>wether or not to draw the gridline on the grid at this tick.</p></div></div></div>
<divclass="CProperty"><divclass=CTopic><h3class=CTitle><aname="$.jqplot.CanvasAxisTickRenderer.isMinorTick"></a>isMinorTick</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.isMinorTick = false</td></tr></table></blockquote><p>if this is a minor tick.</p></div></div></div>
<divclass="CProperty"><divclass=CTopic><h3class=CTitle><aname="$.jqplot.CanvasAxisTickRenderer.angle"></a>angle</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.angle = 0</td></tr></table></blockquote><p>angle of text, measured clockwise from x axis.</p></div></div></div>
<divclass="CProperty"><divclass=CTopic><h3class=CTitle><aname="$.jqplot.CanvasAxisTickRenderer.markSize"></a>markSize</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.markSize = 4</td></tr></table></blockquote><p>Length of the tick marks in pixels. For ‘cross’ style, length will be stoked above and below axis, so total length will be twice this.</p></div></div></div>
<divclass="CProperty"><divclass=CTopic><h3class=CTitle><aname="$.jqplot.CanvasAxisTickRenderer.show"></a>show</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.show = true</td></tr></table></blockquote><p>wether or not to show the tick (mark and label).</p></div></div></div>
<divclass="CProperty"><divclass=CTopic><h3class=CTitle><aname="$.jqplot.CanvasAxisTickRenderer.showLabel"></a>showLabel</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.showLabel = true</td></tr></table></blockquote><p>wether or not to show the label.</p></div></div></div>
<divclass="CProperty"><divclass=CTopic><h3class=CTitle><aname="$.jqplot.CanvasAxisTickRenderer.labelPosition"></a>labelPosition</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.labelPosition = 'auto'</td></tr></table></blockquote><p>’auto’, ‘start’, ‘middle’ or ‘end’. Whether tick label should be positioned so the start, middle, or end of the tick mark.</p></div></div></div>
<divclass="CProperty"><divclass=CTopic><h3class=CTitle><aname="$.jqplot.CanvasAxisTickRenderer.formatter"></a>formatter</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.formatter = $.jqplot.DefaultTickFormatter</td></tr></table></blockquote><p>A class of a formatter for the tick text. The default $.jqplot.DefaultTickFormatter uses sprintf.</p></div></div></div>
<divclass="CProperty"><divclass=CTopic><h3class=CTitle><aname="$.jqplot.CanvasAxisTickRenderer.formatString"></a>formatString</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.formatString = ''</td></tr></table></blockquote><p>string passed to the formatter.</p></div></div></div>
<divclass="CProperty"><divclass=CTopic><h3class=CTitle><aname="$.jqplot.CanvasAxisTickRenderer.prefix"></a>prefix</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.prefix = ''</td></tr></table></blockquote><p>String to prepend to the tick label. Prefix is prepended to the formatted tick label.</p></div></div></div>
<divclass="CProperty"><divclass=CTopic><h3class=CTitle><aname="$.jqplot.CanvasAxisTickRenderer.fontFamily"></a>fontFamily</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.fontFamily = '"Trebuchet MS", Arial, Helvetica, sans-serif'</td></tr></table></blockquote><p>css spec for the font-family css attribute.</p></div></div></div>
<divclass="CProperty"><divclass=CTopic><h3class=CTitle><aname="$.jqplot.CanvasAxisTickRenderer.fontSize"></a>fontSize</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.fontSize = '10pt'</td></tr></table></blockquote><p>CSS spec for font size.</p></div></div></div>
<divclass="CProperty"><divclass=CTopic><h3class=CTitle><aname="$.jqplot.CanvasAxisTickRenderer.fontWeight"></a>fontWeight</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.fontWeight = 'normal'</td></tr></table></blockquote><p>CSS spec for fontWeight</p></div></div></div>
<divclass="CProperty"><divclass=CTopic><h3class=CTitle><aname="$.jqplot.CanvasAxisTickRenderer.fontStretch"></a>fontStretch</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.fontStretch = 1.0</td></tr></table></blockquote><p>Multiplier to condense or expand font width. Applies only to browsers which don’t support canvas native font rendering.</p></div></div></div>
<divclass="CProperty"><divclass=CTopic><h3class=CTitle><aname="$.jqplot.CanvasAxisTickRenderer.textColor"></a>textColor</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.textColor = '#666666'</td></tr></table></blockquote><p>css spec for the color attribute.</p></div></div></div>
<divclass="CProperty"><divclass=CTopic><h3class=CTitle><aname="$.jqplot.CanvasAxisTickRenderer.enableFontSupport"></a>enableFontSupport</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.enableFontSupport = true</td></tr></table></blockquote><p>true to turn on native canvas font support in Mozilla 3.5+ and Safari 4+. If true, tick label will be drawn with canvas tag native support for fonts. If false, tick label will be drawn with Hershey font metrics.</p></div></div></div>
<divclass="CProperty"><divclass=CTopic><h3class=CTitle><aname="$.jqplot.CanvasAxisTickRenderer.pt2px"></a>pt2px</h3><divclass=CBody><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.pt2px = null</td></tr></table></blockquote><p>Point to pixel scaling factor, used for computing height of bounding box around a label. The labels text renderer has a default setting of 1.4, which should be suitable for most fonts. Leave as null to use default. If tops of letters appear clipped, increase this. If bounding box seems too big, decrease. This is an issue only with the native font renderering capabilities of Mozilla 3.5 and Safari 4 since they do not provide a method to determine the font height.</p></div></div></div>
<divclass=CToolTipid="tt1"><divclass=CProperty><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.mark = 'outside'</td></tr></table></blockquote>tick mark on the axis. </div></div><divclass=CToolTipid="tt2"><divclass=CProperty><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.showMark = true</td></tr></table></blockquote>wether or not to show the mark on the axis.</div></div><divclass=CToolTipid="tt3"><divclass=CProperty><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.showGridline = true</td></tr></table></blockquote>wether or not to draw the gridline on the grid at this tick.</div></div><divclass=CToolTipid="tt4"><divclass=CProperty><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.isMinorTick = false</td></tr></table></blockquote>if this is a minor tick.</div></div><divclass=CToolTipid="tt5"><divclass=CProperty><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.angle = 0</td></tr></table></blockquote>angle of text, measured clockwise from x axis.</div></div><divclass=CToolTipid="tt6"><divclass=CProperty><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.markSize = 4</td></tr></table></blockquote>Length of the tick marks in pixels. </div></div><divclass=CToolTipid="tt7"><divclass=CProperty><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.show = true</td></tr></table></blockquote>wether or not to show the tick (mark and label).</div></div><divclass=CToolTipid="tt8"><divclass=CProperty><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.showLabel = true</td></tr></table></blockquote>wether or not to show the label.</div></div><divclass=CToolTipid="tt9"><divclass=CProperty><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.labelPosition = 'auto'</td></tr></table></blockquote>‘auto’, ‘start’, ‘middle’ or ‘end’. </div></div><divclass=CToolTipid="tt10"><divclass=CProperty><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.formatter = $.jqplot.DefaultTickFormatter</td></tr></table></blockquote>A class of a formatter for the tick text. </div></div><divclass=CToolTipid="tt11"><divclass=CProperty><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.formatString = ''</td></tr></table></blockquote>string passed to the formatter.</div></div><divclass=CToolTipid="tt12"><divclass=CProperty><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.prefix = ''</td></tr></table></blockquote>String to prepend to the tick label. </div></div><divclass=CToolTipid="tt13"><divclass=CProperty><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.fontFamily = '"Trebuchet MS", Arial, Helvetica, sans-serif'</td></tr></table></blockquote>css spec for the font-family css attribute.</div></div><divclass=CToolTipid="tt14"><divclass=CProperty><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.fontSize = '10pt'</td></tr></table></blockquote>CSS spec for font size.</div></div><divclass=CToolTipid="tt15"><divclass=CProperty><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.fontWeight = 'normal'</td></tr></table></blockquote>CSS spec for fontWeight</div></div><divclass=CToolTipid="tt16"><divclass=CProperty><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.fontStretch = 1.0</td></tr></table></blockquote>Multiplier to condense or expand font width. </div></div><divclass=CToolTipid="tt17"><divclass=CProperty><blockquote><tableborder=0cellspacing=0cellpadding=0class=Prototype><tr><td>this.textColor = '#666666'</td></tr></table></blockquote>css spec for the color attribute.</div></div><divclass=CToolTipid="tt18"><div