User Guide

Customizing the List component 769
Setting styles for all List components in a document
The List class inherits from the ScrollSelectList class. The default class-level style properties
are defined on the ScrollSelectList class, which the Menu component and all List-based
components extend. You can set new default style values on this class directly, and the new
settings are reflected in all affected components.
_global.styles.ScrollSelectList.setStyle("backgroundColor", 0xFF00AA);
To set a style property on the List and List-based components only, you can create a new
CSSStyleDeclaration instance and store it in _global.styles.List.
import mx.styles.CSSStyleDeclaration;
if (_global.styles.List == undefined) {
_global.styles.List = new CSSStyleDeclaration();
}
_global.styles.List.setStyle("backgroundColor", 0xFF00AA);
selectionDisabledColor
Both The background color of a selected row. The default
value is a 0xDDDDDD (medium gray). Because the
default value for this property is the same as the
default for
backgroundDisabledColor, the selection is
not visible when the component is disabled unless
one of these style properties is changed.
selectionEasing
Both A reference to the easing equation used to control the
transition between selection states. This applies only
for the transition from a normal to a selected state.
The default equation uses a sine in/out formula. For
more information, see “Customizing component
animations” in Using Components.
textRollOverColor
Both The color of text when the pointer rolls over it. The
default value is 0x2B333C (dark gray). This style is
important when you set
rollOverColor, because the
two settings must complement each other so that text
is easily viewable during a rollover.
textSelectedColor
Both The color of text in the selected row. The default value
is 0x005F33 (dark gray). This style is important
when you set
selectionColor, because the two
settings must complement each other so that text is
easily viewable while selected.
useRollOver
Both Determines whether rolling over a row activates
highlighting. The default value is
true.
Style Theme Description