YUI recommends YUI 3.

YUI 2 has been deprecated since 2011. This site acts as an archive for files and documentation.

Yahoo! UI Library

Charts Widget  2.8.2r1

Yahoo! UI Library > charts > YAHOO.widget.CartesianChart
Search:
 
Filters

Class YAHOO.widget.CartesianChart - uses YAHOO.widget.Chart

CartesianChart class for the YUI Charts widget.

Constructor

YAHOO.widget.CartesianChart ( type , containerId , dataSource , attributes )
Parameters:
type <String> The char type. May be "line", "column", or "bar"
containerId <HTMLElement> Container element for the Flash Player instance.
dataSource <YAHOO.util.DataSource> DataSource instance.
attributes <object> (optional) Object literal of configuration values.

Properties

_xAxisLabelFunctions - private String

Stores a reference to the xAxis labelFunction created by YAHOO.widget.Chart.createProxyFunction()

_yAxisLabelFunctions - private Array

Stores a reference to the yAxis labelFunctions created by YAHOO.widget.Chart.createProxyFunction()

Methods

_getClonedAxis

private void _getClonedAxis ( )
Receives an axis object, creates a proxy function for the labelFunction and returns the updated object.

_getXField

private void _getXField ( )
Getter for the xField attribute.

_getYField

private void _getYField ( )
Getter for the yField attribute.

_initAttributes

private void _initAttributes ( )
Initializes the attributes.

_removeAxisFunctions

private void _removeAxisFunctions ( )
Removes axis functions contained in an array

_setConstrainViewport

private void _setConstrainViewport ( )
Setter for the constrainViewport attribute

_setXAxes

private void _setXAxes ( )
Setter for the xAxes attribute

_setXAxis

private void _setXAxis ( )
Setter for the xAxis attribute.

_setXField

private void _setXField ( )
Setter for the xField attribute.

_setYAxes

private void _setYAxes ( )
Setter for the yAxes attribute.

_setYAxis

private void _setYAxis ( )
Setter for the yAxis attribute.

_setYField

private void _setYField ( )
Setter for the yField attribute.

setSeriesStylesByIndex

void setSeriesStylesByIndex ( index , style )
Sets the style object for a single series based on its index
Parameters:
index <Number> The position within the series definition to apply the style
style <object> Style object to be applied to the selected series

Events

beforeConstrainViewportChange

beforeConstrainViewportChange ( event )
Fires before the value for the configuration attribute 'constrainViewport' changes. Return false to cancel the attribute change.
Parameters:
event <{oldValue: any, newValue: any}> An object containing the previous attribute value and the new value.

beforeXAxesChange

beforeXAxesChange ( event )
Fires before the value for the configuration attribute 'xAxes' changes. Return false to cancel the attribute change.
Parameters:
event <{oldValue: any, newValue: any}> An object containing the previous attribute value and the new value.

beforeXAxisChange

beforeXAxisChange ( event )
Fires before the value for the configuration attribute 'xAxis' changes. Return false to cancel the attribute change.
Parameters:
event <{oldValue: any, newValue: any}> An object containing the previous attribute value and the new value.

beforeXFieldChange

beforeXFieldChange ( event )
Fires before the value for the configuration attribute 'xField' changes. Return false to cancel the attribute change.
Parameters:
event <{oldValue: any, newValue: any}> An object containing the previous attribute value and the new value.

beforeYAxesChange

beforeYAxesChange ( event )
Fires before the value for the configuration attribute 'yAxes' changes. Return false to cancel the attribute change.
Parameters:
event <{oldValue: any, newValue: any}> An object containing the previous attribute value and the new value.

beforeYAxisChange

beforeYAxisChange ( event )
Fires before the value for the configuration attribute 'yAxis' changes. Return false to cancel the attribute change.
Parameters:
event <{oldValue: any, newValue: any}> An object containing the previous attribute value and the new value.

beforeYFieldChange

beforeYFieldChange ( event )
Fires before the value for the configuration attribute 'yField' changes. Return false to cancel the attribute change.
Parameters:
event <{oldValue: any, newValue: any}> An object containing the previous attribute value and the new value.

constrainViewportChange

constrainViewportChange ( event )
Fires when the value for the configuration attribute 'constrainViewport' changes.
Parameters:
event <{oldValue: any, newValue: any}> An object containing the previous attribute value and the new value.

xAxesChange

xAxesChange ( event )
Fires when the value for the configuration attribute 'xAxes' changes.
Parameters:
event <{oldValue: any, newValue: any}> An object containing the previous attribute value and the new value.

xAxisChange

xAxisChange ( event )
Fires when the value for the configuration attribute 'xAxis' changes.
Parameters:
event <{oldValue: any, newValue: any}> An object containing the previous attribute value and the new value.

xFieldChange

xFieldChange ( event )
Fires when the value for the configuration attribute 'xField' changes.
Parameters:
event <{oldValue: any, newValue: any}> An object containing the previous attribute value and the new value.

yAxesChange

yAxesChange ( event )
Fires when the value for the configuration attribute 'yAxes' changes.
Parameters:
event <{oldValue: any, newValue: any}> An object containing the previous attribute value and the new value.

yAxisChange

yAxisChange ( event )
Fires when the value for the configuration attribute 'yAxis' changes.
Parameters:
event <{oldValue: any, newValue: any}> An object containing the previous attribute value and the new value.

yFieldChange

yFieldChange ( event )
Fires when the value for the configuration attribute 'yField' changes.
Parameters:
event <{oldValue: any, newValue: any}> An object containing the previous attribute value and the new value.

Configuration Attributes

constrainViewport - Boolean

Determines whether the viewport is constrained to prevent series data from overflow.

xAxes - Array

Custom configurations for the horizontal x axes.

xAxis - Axis

A custom configuration for the horizontal x axis.

xField - String

The field in each item that corresponds to a value on the x axis.

yAxes - Array

Custom configurations for the vertical y axes.

yAxis - Axis

A custom configuration for the vertical y axis.

yField - String

The field in each item that corresponds to a value on the x axis.


Copyright © 2010 Yahoo! Inc. All rights reserved.