Customizing the NumericStepper component

You can transform a NumericStepper component horizontally and vertically both while authoring and at runtime. While authoring, select the component on the Stage and use the Free Transform tool or any of the Modify > Transform commands. At runtime, use the setSize() method (see UIObject.setSize()) or any applicable properties and methods of the NumericStepper class. See NumericStepper class.

Resizing the NumericStepper component does not change the size of the down and up arrow buttons. If the stepper is resized greater than the default height, the stepper buttons are pinned to the top and the bottom of the component. The stepper buttons always appear to the right of the text box.

Using styles with the NumericStepper component

You can set style properties to change the appearance of a stepper instance. If the name of a style property ends in "Color", it is a color style property and behaves differently than non-color style properties. For more information, see Using styles to customize component color and text.

A NumericStepper component supports the following Halo styles:

Style

Description

themeColor

The background of a component. This is the only color style that doesn't inherit its value. Possible values are "haloGreen", "haloBlue", and "haloOrange".

color

The text of a component label.

disabledColor

The disabled color for text.

fontFamily

The font name for text.

fontSize

The point size for the font.

fontStyle

The font style; either "normal", or "italic".

fontWeight

The font weight; either "normal", or "bold".

textDecoration

The text decoration; either "none", or "underline".

textAlign

The text alignment; either "left", "right", or "center".

Using skins with the NumericStepper component

The NumericStepper component skins to represent its visual states. To skin the NumericStepper component while authoring, modify skin symbols in the library and re-export the component as a SWC. The skin symbols are located in the Flash UI Components 2/Themes/MMDefault/Stepper Elements/states folder in the library. For more information, see About skinning components.

If a stepper is enabled, the down and up buttons display their over states when the pointer moves over them. The buttons display their down state when clicked. The buttons return to their over state when the mouse is released. If the pointer moves off the buttons while the mouse is pressed, the buttons return to their original state.

If a stepper is disabled it displays its disabled state, regardless of user interaction.

A NumericStepper component uses the following skin properties:

Property

Description

upArrowUp

The up arrow's up state. The default value is StepUpArrowUp.

upArrowDown

The up arrow's pressed state. The default value is StepUpArrowDown.

upArrowOver

The up arrow's over state. The default value is StepUpArrowOver.

upArrowDisabled

The up arrow's disabled state. The default value is StepUpArrowDisabled.

downArrowUp

The down arrow's up state. The default value is StepDownArrowUp.

downArrowDown

The down arrow's down state. The default value is StepDownArrowDown.

downArrowOver

The down arrow's over state. The default value is StepDownArrowOver.

downArrowDisabled

The down arrow's disabled state. The default value is StepDownArrowDisabled.