dojox/charting/axis2d/Base (version 1.10)

dojox/charting/Element

Summary

The base class for any axis. This is more of an interface/API definition than anything else; see dojox.charting.axis2d.Default for more details.

Usage

var foo = new Base(chart,kwArgs);
dojox/charting/axis2d/Base
Parameter Type Description
chart dojox/charting/Chart

The chart this axis belongs to.

kwArgs Object
Optional

An optional arguments object to define the axis parameters.

Property Summary

  • chartThe parent chart for this element.
  • dirtyA flag indicating whether or not this element needs to be rendered.
  • groupThe visual GFX group representing this element.
  • htmlElementAny DOMNodes used as a part of this element (such as HTML-based labels).
  • htmlElements
  • renderingOptions

Method Summary

  • _plotFill(fill,dim,offsets)
  • _pseudoRadialFill(fill,center,radius,start,end)
  • _shapeFill(fill,bbox)
  • calculate(min,max,span) Stub function to run the calculations needed for drawing this axis.
  • cleanGroup(creator) Clean any elements (HTML or GFX-based) out of our group, and create a new one.
  • clear() Stub function for clearing the axis.
  • destroy() API addition to conform to the rest of the Dojo Toolkit's standard.
  • destroyHtmlElements() Destroy any DOMNodes that may have been created as a part of this element.
  • getGroup()
  • getOffsets() A stub function to return any offsets needed for axis and series rendering.
  • getScaler() A stub function to return the scaler object created during calculate.
  • getTextWidth(s,font)
  • getTextWithLimitCharCount(s,font,wcLimit,truncated) Get the truncated string based on the limited character count(dichotomy algorithm)
  • getTextWithLimitLength(s,font,limitWidth,truncated) Get the truncated string based on the limited width in px(dichotomy algorithm)
  • getTicks() A stub function to return the object that helps define how ticks are rendered.
  • initialized() Return a flag as to whether or not this axis has been initialized.
  • purgeGroup() Clear any elements out of our group, and destroy the group.
  • render(dim,offsets) Stub function to render this axis.

Properties

chart

The parent chart for this element.

dirty

A flag indicating whether or not this element needs to be rendered.

group

The visual GFX group representing this element.

htmlElement

Any DOMNodes used as a part of this element (such as HTML-based labels).

htmlElements
renderingOptions

Methods

_plotFill(fill,dim,offsets)
Parameter Type Description
fill undefined
dim undefined
offsets undefined
Returns:undefined
_pseudoRadialFill(fill,center,radius,start,end)
Parameter Type Description
fill undefined
center undefined
radius undefined
start undefined
end undefined
Returns:undefined | object
_shapeFill(fill,bbox)
Parameter Type Description
fill undefined
bbox undefined
Returns:undefined
calculate(min,max,span)

Stub function to run the calculations needed for drawing this axis.

Parameter Type Description
min undefined
max undefined
span undefined
Returns:dojox/charting/axis2d/Base | function

A reference to the axis for functional chaining.

cleanGroup(creator)

Clean any elements (HTML or GFX-based) out of our group, and create a new one.

Parameter Type Description
creator dojox/gfx/shape.Surface
Optional

An optional surface to work with.

Returns:dojox/charting/Element | function

A reference to this object for functional chaining.

clear()

Stub function for clearing the axis.

Returns:dojox/charting/axis2d/Base | function

A reference to the axis for functional chaining.

destroy()

API addition to conform to the rest of the Dojo Toolkit's standard.

destroyHtmlElements()

Destroy any DOMNodes that may have been created as a part of this element.

getGroup()
Returns:undefined
getOffsets()

A stub function to return any offsets needed for axis and series rendering.

Returns:Object | object

An object of the form { l, r, t, b }.

getScaler()

A stub function to return the scaler object created during calculate.

Returns:Object | null

The scaler object (see dojox.charting.scaler.linear for more information)

getTextWidth(s,font)
Parameter Type Description
s undefined
font undefined
Returns:number
getTextWithLimitCharCount(s,font,wcLimit,truncated)

Get the truncated string based on the limited character count(dichotomy algorithm)

Parameter Type Description
s String
Optional

candidate text.

font String
Optional

text's font style.

wcLimit Number
Optional

text limited character count.

truncated Boolean
Optional

whether the input text(s) has already been truncated.

Returns:Object | object
{
    text: processed text, maybe truncated or not,
    truncated: whether text has been truncated
}
getTextWithLimitLength(s,font,limitWidth,truncated)

Get the truncated string based on the limited width in px(dichotomy algorithm)

Parameter Type Description
s String
Optional

candidate text.

font String
Optional

text's font style.

limitWidth Number
Optional

text limited width in px.

truncated Boolean
Optional

whether the input text(s) has already been truncated.

Returns:Object | object
{
    text: processed text, maybe truncated or not,
    truncated: whether text has been truncated
}
getTicks()

A stub function to return the object that helps define how ticks are rendered.

Returns:Object | null

The ticks object.

initialized()

Return a flag as to whether or not this axis has been initialized.

Returns:Boolean | boolean

If the axis is initialized or not.

purgeGroup()

Clear any elements out of our group, and destroy the group.

Returns:dojox/charting/Element | function

A reference to this object for functional chaining.

render(dim,offsets)

Stub function to render this axis.

Parameter Type Description
dim undefined
offsets undefined
Returns:dojox/charting/axis2d/Base | function

A reference to the axis for functional chaining.

Error in the documentation? Can’t find what you are looking for? Let us know!