Packageardisia.charts.baseClasses
Classpublic class ChartBase
InheritanceChartBase Inheritance spark.components.supportClasses.SkinnableComponent
Subclasses Donut, Funnel, Radar, TreeMap

Base class for certain Ardisia chart classes.

Default MXML PropertydataProvider



Public Properties
 PropertyDefined By
  colorField : String
Field name on the data to pull the node's color.
ChartBase
  colorFormatFunction : Function
User provided function that returns the color for the series when passed the series data object.
ChartBase
  dataProvider : ListCollectionView
The dataProvider for the chart.
ChartBase
  dataTipField : String
Field name on the data to pull the node's data tip string.
ChartBase
  dataTipFormatFunction : Function
User provided function that gets the message to display with the data tip.
ChartBase
  dataTipHideDelay : Number = 350
Delay before the data tip is hidden.
ChartBase
  dataTipInstance : IDataRenderer
Instance of the data tip.
ChartBase
  excludedSeries : Array
Array of the series that should not be displayed.
ChartBase
  highlightAlpha : Number = 0.4
When series data is highlighted, the alpha to apply.
ChartBase
  highlightDuration : Number = 250
Duration of the highlight effects.
ChartBase
  showDataTip : Boolean = true
True to display a data tip on hover.
ChartBase
Protected Properties
 PropertyDefined By
  numberFormatter : NumberFormatter
Default number formatter.
ChartBase
Public Methods
 MethodDefined By
  
Hide the data tip.
ChartBase
  
setHighlightedSeries(item:Object):void
Highlight the passed series.
ChartBase
Protected Methods
 MethodDefined By
  
eventHandler(event:Event):void
Handles the events for the class.
ChartBase
  
getDataTipContent(data:Object):Object
Returns the contents for the data tip.
ChartBase
  
setupDataTip(data:Object):void
Setup the data tip.
ChartBase
  
updateDisplayList(unscaledWidth:Number, unscaledHeight:Number):void
[override]
ChartBase
Events
 Event Summary Defined By
  Dispatched when the chart's legend should be updated.ChartBase
Skin Parts

This component uses skins made up of skin parts. Do not set the skin parts directly. The component's skin sets the skin parts.


 Skin Part Description Defined By
  
dataTipFactoryPart:mx.core.IFactory
Required: false Part Type: Dynamic
Displays the data tip when a node is hovered.

The IFactory must return an object of type IDataRenderer
ChartBase
  
skinLayerPart:Layer
Required: false Part Type: Dynamic
Container for the content added to the skin.
ChartBase
Skin States

To skin the component, implement a skin that defines the following states. Although you must implement all skin states, a skin state can be empty. An empty skin state specifies no changes to the default skin state.


 Skin State Description Defined By
  
disabled
ChartBase
  
normal
ChartBase
Property Detail
colorFieldproperty
colorField:String

Field name on the data to pull the node's color.

The default value is "".


Implementation
    public function get colorField():String
    public function set colorField(value:String):void
colorFormatFunctionproperty 
colorFormatFunction:Function

User provided function that returns the color for the series when passed the series data object.

The function has the following signature:

	  funcName(value:Object):uint
	  

The default value is null.


Implementation
    public function get colorFormatFunction():Function
    public function set colorFormatFunction(value:Function):void
dataProviderproperty 
dataProvider:ListCollectionView

The dataProvider for the chart. This property is bindable and is bound to "dataProviderChanged" events.

The default value is null.

This property can be used as the source for data binding.


Implementation
    public function get dataProvider():ListCollectionView
    public function set dataProvider(value:ListCollectionView):void
dataTipFieldproperty 
public var dataTipField:String

Field name on the data to pull the node's data tip string.

The default value is "".

dataTipFormatFunctionproperty 
public var dataTipFormatFunction:Function

User provided function that gets the message to display with the data tip. The function takes a data object and the series color and returns either a TextFlow or a String for the data tip contents.

The function has the following signature:

	  funcName(value:Object, seriesColor:uint):Object
	  

The default value is null.

dataTipHideDelayproperty 
public var dataTipHideDelay:Number = 350

Delay before the data tip is hidden.

The default value is 350.

dataTipInstanceproperty 
public var dataTipInstance:IDataRenderer

Instance of the data tip.

excludedSeriesproperty 
excludedSeries:Array

Array of the series that should not be displayed.

Can be used instead of a filter on the data provider so that the index of the series doesn't change, and therefore the default series color will not change.

The default value is null.


Implementation
    public function get excludedSeries():Array
    public function set excludedSeries(value:Array):void
highlightAlphaproperty 
public var highlightAlpha:Number = 0.4

When series data is highlighted, the alpha to apply.

The default value is 0.4.

highlightDurationproperty 
public var highlightDuration:Number = 250

Duration of the highlight effects.

Set to 0 to skip.

The default value is 250.

numberFormatterproperty 
protected var numberFormatter:NumberFormatter

Default number formatter.

showDataTipproperty 
public var showDataTip:Boolean = true

True to display a data tip on hover.

The default value is true.

Method Detail
eventHandler()method
protected function eventHandler(event:Event):void

Handles the events for the class.

Parameters

event:Event — the Event that triggered the handler

getDataTipContent()method 
protected function getDataTipContent(data:Object):Object

Returns the contents for the data tip. Uses the "dataTipField" first, then the "dataTipFormatFunction" function, then the class default.

Can return a TextFlow or a String.

Parameters

data:Object — Object

Returns
Object — Object
hideDataTip()method 
public function hideDataTip():void

Hide the data tip.

setHighlightedSeries()method 
public function setHighlightedSeries(item:Object):void

Highlight the passed series.

Pass a null value to remove any applied effects.

Parameters

item:Object — Object

setupDataTip()method 
protected function setupDataTip(data:Object):void

Setup the data tip. Must be positioned elsewhere.

Parameters

data:Object — Object the data to setup the content of the data tip

updateDisplayList()method 
override protected function updateDisplayList(unscaledWidth:Number, unscaledHeight:Number):void

Parameters

unscaledWidth:Number
 
unscaledHeight:Number

Event Detail
updateLegend Event
Event Object Type: spark.events.RendererExistenceEvent
RendererExistenceEvent.type property = ardisia.charts.events.ChartEvent

Dispatched when the chart's legend should be updated.