Main Page | Packages | Class Tree | Index | Help

xp.charting

class AxisChart

MovieClip
  |
  +--xp.system.UIControl
        |
        +--xp.charting.AxisChart


class AxisChart
extends UIControl

Host class for the all charts with an axis


Author:
ProWin Computers Ltd. - Rob Edgar

Version:
3.0.0.000

See also:


Field Summary

public
autoDraw: Boolean
Determines whether chart is automatically redrawn when the componentis invalidated

public
autoScaleXAxis: Boolean
Determines whether the x axis extents will be automatcially calculated. If set to false you mustset them manually yourself. This can be useful if you have several charts and you wish them all to have the same extents

public
autoScaleYAxis: Boolean
Determines whether the y axis extenst will be automatcially calculated. If set to false you mustset them manually yourself. This can be useful if you have several charts and you wish them all to have the same extents

public
bands: Array
the bands array

public
chartType: String
the default chart type

public static
classInfo: Object
A static class information object

public
crosshairDisplayMode: String
Controls the croshair display. One of none,free,plot.

public
dataLabelPosition: String
Determines where data label will be placed

public
drawHGridlines: Boolean
Should horizontal gridlines be drawn

public
drawVGridlines: Boolean
Should vertical gridlines be drawn

public
dwellLabelPosition: String
Determines where dwell label will be placed

public
gridlineColor: Number
The color of the gridlines


isColumnsInit


public
label: MovieClip


public
legend: MovieClip
the control for displaying the legend

public
lines: Array
the lines array


manualInit


public
markerType
controls the type of marker that is shown

public
maxXAxisValue: Number
Sets the max value of the x labels displayed when autocalc is turned off

public
maxYAxisValue: Number
Sets the max value of the y labels displayed when autocalc is turned off

public
minXAxisValue: Number
Sets the min value of the x labels displayed when autocalc is turned off

public
minYAxisValue: Number
Sets the min value of the y labels displayed when autocalc is turned off

public
monthLabelFormat: String
Format for months dislayed on the x axis

public
numXLabels: Number
Sets the number of x labels displayed when autocalc is turned off

public
numYLabels: Number
Sets the number of y labels displayed when autocal is turned off

public
placementYAxis: String
Controls the placemtn of the y axis

public
plotBackgroundVisible: Boolean


public
prefixYAxis: String
The prefix for y axis labels

public
showAnnotations: Boolean
Should we display annotations when mouse over a marker. An event is raised when the marker is moused over so u can display annotations in anyway you choose

public
showMarkers: Boolean
Are data point markers displayed on series

public
showXAxisLabels: Boolean
Controls whether the x axis labels are shown

public
showYAxisLabels: Boolean
Controls whether the y axis labels are shown

public
styleClass: String
The name of the style class this instance will use.

public
suffixYAxis: String
the suffix for y axis labels

public
yearLabelFormat: String
Format for years dislayed on the x axis

Fields inherited from class xp.system.UIControl

__layout, allowDrop, autoLayout, bindingDefaultValue, bindingFormatter, bindingPath, bindingSource, bindingType, bindingValidator, border, causesValidation, classInfo, clickOnENTER, clickOnSPACE, container, context, data, disableAcceptButton, disableCancelButton, enableBGMouseEvents, enableDblClickEvent, enableKeyDownEvents, enableKeyEvents, enableKeyUpEvents, enableMouseWheelEvents, formatterOptions, horizontalAlignment, index, isBinding, itemId, logEnabled, parent, parentContainer, parentForm, percentageHeight, percentageWidth, styleClass, tabIndex, tabStop, tooltip, tree, verticalAlignment

Property Summary

public
axisX (read-only)
primary x axis descriptor

public
axisX2 (read-only)
secondary x axis descriptor

public
axisY (read-only)
primary y axis descriptor

public
axisY2 (read-only)
secondary y axis descriptor

public
dataProvider: Object (read, write)
The source of the chart items.

public
legendPlacement: String (read, write)


public
plotBackground: Object (read, write)


Properties inherited from class xp.system.UIControl

alpha, autosize, background, backgroundVisible, bindings, borderBrush, borderRadius, borderShadow, borderStyle, borderThickness, bottom, dataSource, enableMouseEvents, focusManager, height, id, isEnabled, isFocused, isMouseOver, isPressed, isSelected, isValid, layout, left, margin, maxHeight, maxWidth, measuredHeight, measuredMinHeight, measuredMinWidth, measuredWidth, minHeight, minWidth, padding, readOnly, resources, right, styleName, top, triggers, visible, width, x, y

Constructor

public
AxisChart ( )


Method Summary

public
addAnnotation ( series, plot, text ): Void
Add a single annotation

public
addBand ( band: Band ): Band
Add a single band

public
addLine ( line: Line ): Line
Add a single line

public
addSeries ( series: Object, doDraw: Boolean ): Object
Add a series descriptor

public
addTool ( type: String ): Object
adds the specified tool type to the chart

public
drawChart ( ): Void
Draw the entire chart

public
drawSeries ( index ): Void
Draws a single series

public
getClass ( ): Function
Returns a reference to the components static class.

public
getDwellLabel ( ): Label


public
getTool ( index: Number ): Object
returns a reference to a tool

public
getXSeries ( ): Object
Retrieves the x axis descriptor

public
getYSeries ( index ): Object
returns the yseries descriptor

public
invalidateChart ( ): Void


public static
newInstance ( owner, instanceId, depth, initObj )
Creates a new Instance of this class

public
removeSeries ( seriesName: String ): Void
Remove a data series

public
removeTool ( index: Number ): Void
removes the tool from the chart

public
setAreaSeries ( seriesName: String, data: Object, field: String, axis: Number, props: Object, doDraw: Boolean ): Object
Add a area data series

public
setBarSeries ( seriesName: String, data: Object, field: String, axis: Number, props: Object, doDraw: Boolean ): Object
Add a Bar data series

public
setHiLoSeries ( seriesName: String, data: Object, field: String, axis: Number, props: Object, doDraw: Boolean ): Object
Add a HiLo data series

public
setLineSeries ( seriesName: String, data: Object, field: String, axis: Number, props: Object, doDraw: Boolean ): Object
Add a Line data series

public
setSeries ( graphType: String, seriesName: String, data: Object, field: String, axis: Number, props: Object, doDraw: Boolean ): Object
Add a data series

public
setSeriesAnnotations ( series, annos, plots ): Void
Add annotations

public
setSeriesAttribute ( index, attribute: String, value: Object ): Void
Update a series

public
setSeriesAttributes ( index, props: Object ): Void
Update a series

public
setStackedBarSeries ( seriesName: String, data: Object, field: String, axis: Number, props: Object, doDraw: Boolean ): Object
Add a StackedBar data series

public
setXSeries ( dp: Object, field: String, type: String, props: Object ): Void
Add the x axis data array

public
setXSeriesFrequency ( frequency: String, startDate: Date, endDate: Date, units: Number ): Void
Create and add the x axis date array from a range of dates

public
setYSeries ( seriesName: String, data: Object, field: String, axis: Number, props: Object, doDraw: Boolean ): Object
Add a data series

public
setYSeriesAxis2 ( seriesName: String ): Void
sets the series that will be used to calculate the second yAxis

public
updateChartDescriptor ( ): Void
make sure the descriptor is up to date before we start to draw

public
updateYSeries ( index, dp: Array, doDraw: Boolean ): Void
Update the data for a series

Methods inherited from class xp.system.UIControl

addBinding, addBindings, addEventListener, addPropertyTrigger, applyStyle, beginDeferUpdate, canUpdate, centerContent, checkState, containsFocus, destroy, destroyObject, drawFocus, endDeferUpdate, findFocusFromObject, findFocusInChildren, getBinding, getBounds, getCenter, getClass, getFocus, getFocusManager, getFocusRect, getLocation, getPropertyValue, getSize, getStateName, getTrigger, globalToLocalPoint, invalidate, invalidateLayout, invalidateSize, invalidateSizeAndLayout, invalidChild, isChild, isMouseDirectlyOver, isParent, localToGlobalPoint, localToLocalPoint, measure, mouseWheel, move, onChildFocus, onKillFocus, onSetFocus, processEnterKey, processEscapeKey, processTabKey, redraw, refresh, removeEventListener, routeEvent, setBounds, setFocus, setLocation, setPropertyValue, setSize, setValueChanged, update, validate



Field Documentation

autoDraw

public var autoDraw: Boolean
Determines whether chart is automatically redrawn when the componentis invalidated

autoScaleXAxis

public var autoScaleXAxis: Boolean
Determines whether the x axis extents will be automatcially calculated. If set to false you mustset them manually yourself. This can be useful if you have several charts and you wish them all to have the same extents

autoScaleYAxis

public var autoScaleYAxis: Boolean
Determines whether the y axis extenst will be automatcially calculated. If set to false you mustset them manually yourself. This can be useful if you have several charts and you wish them all to have the same extents

bands

public var bands: Array
the bands array

chartType

public var chartType: String
the default chart type

classInfo

public static var classInfo: Object
A static class information object

Every class has an associated classInfo object that holds the version and other static information. The classInfo can be accessed either directly by referencing the static class or by calling getClass() on any class instance.

crosshairDisplayMode

public var crosshairDisplayMode: String
Controls the croshair display. One of none,free,plot.

dataLabelPosition

public var dataLabelPosition: String
Determines where data label will be placed

If set to inside our outside a data label will be displayed.

drawHGridlines

public var drawHGridlines: Boolean
Should horizontal gridlines be drawn

drawVGridlines

public var drawVGridlines: Boolean
Should vertical gridlines be drawn

dwellLabelPosition

public var dwellLabelPosition: String
Determines where dwell label will be placed

When the mouse hovers over a marker a label is displayed. This property controls the placement. One of outside,inside,tooltip,none.

gridlineColor

public var gridlineColor: Number
The color of the gridlines

isColumnsInit

var isColumnsInit

label

public var label: MovieClip

legend

public var legend: MovieClip
the control for displaying the legend

lines

public var lines: Array
the lines array

manualInit

var manualInit

markerType

public var markerType
controls the type of marker that is shown

maxXAxisValue

public var maxXAxisValue: Number
Sets the max value of the x labels displayed when autocalc is turned off

maxYAxisValue

public var maxYAxisValue: Number
Sets the max value of the y labels displayed when autocalc is turned off

minXAxisValue

public var minXAxisValue: Number
Sets the min value of the x labels displayed when autocalc is turned off

minYAxisValue

public var minYAxisValue: Number
Sets the min value of the y labels displayed when autocalc is turned off

monthLabelFormat

public var monthLabelFormat: String
Format for months dislayed on the x axis

Format for months dislayed on the x axis. One of short,long,onechar

numXLabels

public var numXLabels: Number
Sets the number of x labels displayed when autocalc is turned off

numYLabels

public var numYLabels: Number
Sets the number of y labels displayed when autocal is turned off

placementYAxis

public var placementYAxis: String
Controls the placemtn of the y axis

Controls whether the y axis is placed left or right

plotBackgroundVisible

public var plotBackgroundVisible: Boolean

prefixYAxis

public var prefixYAxis: String
The prefix for y axis labels

The prefix fro y axis labels only the first label is prefixed

showAnnotations

public var showAnnotations: Boolean
Should we display annotations when mouse over a marker. An event is raised when the marker is moused over so u can display annotations in anyway you choose

showMarkers

public var showMarkers: Boolean
Are data point markers displayed on series

showXAxisLabels

public var showXAxisLabels: Boolean
Controls whether the x axis labels are shown

Controls whether the x axis labels are shown

showYAxisLabels

public var showYAxisLabels: Boolean
Controls whether the y axis labels are shown

Controls whether the y axis labels are shown

styleClass

public var styleClass: String
The name of the style class this instance will use.

suffixYAxis

public var suffixYAxis: String
the suffix for y axis labels

Suffix for y axis label, only the first label is suffixed

yearLabelFormat

public var yearLabelFormat: String
Format for years dislayed on the x axis

Format for years dislayed on the x axis. One of short,long


Property Documentation

axisX

public axisX (read-only)
primary x axis descriptor

axisX2

public axisX2 (read-only)
secondary x axis descriptor

axisY

public axisY (read-only)
primary y axis descriptor

axisY2

public axisY2 (read-only)
secondary y axis descriptor

dataProvider

public dataProvider: Object (read, write)
The source of the chart items.

The data model for items viewed in a chart. The value of this property can be an array or any object that implements the DataProvider API.

legendPlacement

public legendPlacement: String (read, write)

plotBackground

public plotBackground: Object (read, write)

Constructor Documentation

AxisChart

public function AxisChart()

Method Documentation

addAnnotation

public function addAnnotation(series,
 plot,
 text): Void
Add a single annotation

Adda single annotation

addBand

public function addBand(band: Band): Band
Add a single band

Add a single band if band is null a new band is created

Parameters:
band
the band to be addded
Returns:
the band that was added

addLine

public function addLine(line: Line): Line
Add a single line

Add a single line, if line is null a new line is created

Parameters:
line
the line to be addded
Returns:
the line that was added

addSeries

public function addSeries(series: Object,
 doDraw: Boolean): Object
Add a series descriptor

Add a descriptor to the chart

Parameters:
series
- series descriptor
doDraw
- if true the series is immediatley drawn

addTool

public function addTool(type: String): Object
adds the specified tool type to the chart

drawChart

public function drawChart(): Void
Draw the entire chart

drawSeries

public function drawSeries(index): Void
Draws a single series

Draws a single series

getClass

public function getClass(): Function
Returns a reference to the components static class.

Overrides:

getDwellLabel

public function getDwellLabel(): Label

getTool

public function getTool(index: Number): Object
returns a reference to a tool

getXSeries

public function getXSeries(): Object
Retrieves the x axis descriptor

The x axis is stored in a descriptor

getYSeries

public function getYSeries(index): Object
returns the yseries descriptor

Parameters:
index
the name of the series or the position of the series in the yseries array

invalidateChart

public function invalidateChart(): Void

newInstance

public static function newInstance(owner,
 instanceId,
 depth,
 initObj)
Creates a new Instance of this class

Creates an instance of a component at runtime. You need to use the import statement and specify the class package name before calling this method. In addition, the component must be in the FLA file’s library.

Parameters:
owner
A reference to the movie clip or object that will contains the new Instance.
instanceId
A string indicating the instance name of the new instance.(optional)
depth
A number indicating the depth of the new instance.(optional)
initObj
An object containing initialization properties for the new instance.(optional)
Returns:
A object that is an instance of the specified class.

removeSeries

public function removeSeries(seriesName: String): Void
Remove a data series

Remove a series to the chart

removeTool

public function removeTool(index: Number): Void
removes the tool from the chart

setAreaSeries

public function setAreaSeries(seriesName: String,
 data: Object,
 field: String,
 axis: Number,
 props: Object,
 doDraw: Boolean): Object
Add a area data series

Add a area series to the chart

setBarSeries

public function setBarSeries(seriesName: String,
 data: Object,
 field: String,
 axis: Number,
 props: Object,
 doDraw: Boolean): Object
Add a Bar data series

Add a Bar series to the chart

setHiLoSeries

public function setHiLoSeries(seriesName: String,
 data: Object,
 field: String,
 axis: Number,
 props: Object,
 doDraw: Boolean): Object
Add a HiLo data series

Add a HiLo series to the chart

setLineSeries

public function setLineSeries(seriesName: String,
 data: Object,
 field: String,
 axis: Number,
 props: Object,
 doDraw: Boolean): Object
Add a Line data series

Add a Line series to the chart

setSeries

public function setSeries(graphType: String,
 seriesName: String,
 data: Object,
 field: String,
 axis: Number,
 props: Object,
 doDraw: Boolean): Object
Add a data series

Add a series to the chart, the type is specified by the graphType param

setSeriesAnnotations

public function setSeriesAnnotations(series,
 annos,
 plots): Void
Add annotations

Add annotations

setSeriesAttribute

public function setSeriesAttribute(index,
 attribute: String,
 value: Object): Void
Update a series

Updates an attribute in a series

Parameters:
index
the index or name of the seris to be updated if null all series are updated
attribute
- name of attribute to be updated
value
- the new value to be assigned to the attribute

setSeriesAttributes

public function setSeriesAttributes(index,
 props: Object): Void
Update a series

Updates a series with the properties in the desc param

Parameters:
index
the index or name of the seris to be updated, if null all series are updated
props
a property bag to be applied to the series

setStackedBarSeries

public function setStackedBarSeries(seriesName: String,
 data: Object,
 field: String,
 axis: Number,
 props: Object,
 doDraw: Boolean): Object
Add a StackedBar data series

Add a StackedBar series to the chart

setXSeries

public function setXSeries(dp: Object,
 field: String,
 type: String,
 props: Object): Void
Add the x axis data array

Supports an array of Dates, Numbers or Strings

setXSeriesFrequency

public function setXSeriesFrequency(frequency: String,
 startDate: Date,
 endDate: Date,
 units: Number): Void
Create and add the x axis date array from a range of dates

Creates an array of dates from start to end date and add the array as the x axis

setYSeries

public function setYSeries(seriesName: String,
 data: Object,
 field: String,
 axis: Number,
 props: Object,
 doDraw: Boolean): Object
Add a data series

Add a series to the chart, the type is determined by the chart type

setYSeriesAxis2

public function setYSeriesAxis2(seriesName: String): Void
sets the series that will be used to calculate the second yAxis

Parameters:
seriesName
the name of the series

updateChartDescriptor

public function updateChartDescriptor(): Void
make sure the descriptor is up to date before we start to draw

updateYSeries

public function updateYSeries(index,
 dp: Array,
 doDraw: Boolean): Void
Update the data for a series

Parameters:
index
the name of the series or the position of the series in the yseries array
dp
the array of date
doDraw
controls whether the chart should be redrawn with the new data

The documentation was generated from the following file:


Generated on 10/30/2005 9:34:02 PM by AS2Doc