User Guide

CellRenderer API 149
Methods provided by the CellRenderer API
The List, DataGrid, Tree, and Menu components give the following methods to the cell when it is
created within the component. You do not need to implement these methods.
Properties provided by the CellRenderer API
The List, DataGrid, Tree, and Menu component give the following properties to the cell when it
is created within the component. You do not need to implement these properties.
CellRenderer.getCellIndex()
Availability
Flash Player 6 (6.0 79.0).
Edition
Flash MX 2004.
Usage
componentInstance.getCellIndex()
Parameters
None.
Returns
An object with two fields: columnIndex and itemIndex.
Description
Method; returns an object with two fields, columnIndex and itemIndex, that locate the cell in
the component. Each field is an integer that indicates a cells column position and item position.
For any components other than the DataGrid component, the value of
columnIndex is always 0.
CellRenderer.setSize() Sets the width and height of a cell.
CellRenderer.setValue() Sets the content to be displayed in the cell.
Method Description
CellRenderer.getCellIndex() Returns an object with two fields, columnIndex and rowIndex,
that indicate the position of the cell.
CellRenderer.getDataLabel() Returns a string containing the name of the cell renderer’s
data field.
Property Description
CellRenderer.listOwner A reference to the List component that contains the cell.
CellRenderer.owner A reference to the row that contains the cell.
Method Description