The FormItem container defines a label and one or more children
arranged horizontally or vertically.
Children can be controls or other containers.
A single Form container can hold multiple FormItem containers.

A flag that indicates whether this object can receive focus
via the TAB key
This is similar to the tabEnabled property
used by the Flash Player.
This is usually true for components that
handle keyboard input, but some components in controlbars
have them set to false because they should not steal
focus from another component like an editor.

[read-only]
A convenience method for determining the unscaled width
of the component
All of a component's drawing and child layout should be done
within a bounding rectangle of this width, which is also passed
as an argument to updateDisplayList().

Indicates whether the security restrictions
would cause any display objects to be omitted from the list returned by calling
the DisplayObjectContainer.getObjectsUnderPoint() method
with the specified point point.

Measures the specified HTML text, which can contain HTML tags such
as <font> and <b>,
assuming that it is displayed
in a single-line UITextField using a UITextFormat
determined by the styles of this UIComponent.

A utility method to update the rotation, scale, and translation of the
transform while keeping a particular point, specified in the component's
own coordinate space, fixed in the parent's coordinate space.

Validates the measured size of the component
If the LayoutManager.invalidateSize() method is called with
this ILayoutManagerClient, then the validateSize() method
is called when it's time to do measurements.

Dispatched by the drag initiator (the component that is the source of the data being dragged) when the drag operation completes, either when you drop the dragged data onto a drop target or when you end the drag-and-drop operation without performing a drop.

Dispatched when the user presses two points of contact over the same InteractiveObject instance on a touch-enabled device (such as presses and releases two fingers over a display object on a mobile phone or tablet with a touch screen).

Dispatched when the user moves a point of contact over the InteractiveObject instance on a touch-enabled device (such as moving a finger from left to right over a display object on a mobile phone or tablet with a touch screen).

Dispatched when the user performs a rotation gesture at a point of contact with an InteractiveObject instance (such as touching two fingers and rotating them over a display object on a mobile phone or tablet with a touch screen).

Dispatched when the user performs a swipe gesture at a point of contact with an InteractiveObject instance (such as touching three fingers to a screen and then moving them in parallel over a display object on a mobile phone or tablet with a touch screen).

Dispatched when the user creates a point of contact with an InteractiveObject instance, then taps on a touch-enabled device (such as placing several fingers over a display object to open a menu and then taps one finger to select a menu item on a mobile phone or tablet with a touch screen).

Dispatched when the user performs a zoom gesture at a point of contact with an InteractiveObject instance (such as touching two fingers to a screen and then quickly spreading the fingers apart over a display object on a mobile phone or tablet with a touch screen).

Dispatched when the user moves an active stylus over this InteractiveObject from outside the object's tree of descendents in the display list (while remaining within the proximity detection threshold of the screen).

Dispatched when a user releases the button on the pointing device after the user first pressed the button over an InteractiveObject instance and then moved the pointing device off of the InteractiveObject instance.

Dispatched when the user moves the point of contact away from InteractiveObject instance on a touch-enabled device (such as drags a finger from one display object to another on a mobile phone or tablet with a touch screen).

Dispatched when the user moves the point of contact over an InteractiveObject instance on a touch-enabled device (such as drags a finger from a point outside a display object to a point over a display object on a mobile phone or tablet with a touch screen).

Dispatched when the user moves the point of contact away from an InteractiveObject instance on a touch-enabled device (such as drags a finger from over a display object to a point outside the display object on a mobile phone or tablet with a touch screen).

Dispatched when the user moves the point of contact over an InteractiveObject instance on a touch-enabled device (such as drags a finger from a point outside a display object to a point over a display object on a mobile phone or tablet with a touch screen).

Dispatched when the user lifts the point of contact over the same InteractiveObject instance on which the contact was initiated on a touch-enabled device (such as presses and releases a finger from a single point over a display object on a mobile phone or tablet with a touch screen).

Styles are either common or associated with a specific theme. If the style is common, it can be used with any theme. If a style is associated with a specific theme, it can only be used if your application uses that theme.

Name of the CSS Style declaration to use for the styles for the
FormItem's label.
By default, the label uses the FormItem's inheritable styles or
those declared by FormItemLabel. This style should be used instead
of FormItemLabel.

direction

Direction of the FormItem subcomponents.
Possible MXML values are "vertical"
or "horizontal".
The default MXML value is "vertical".
Possible ActionScript values are FormItemDirection.VERTICAL
or FormItemDirection.HORIZONTAL.

When direction is "vertical",
the children of the FormItem are stacked vertically
to the right of the FormItem label.
When direction is "horizontal",
the children are placed in a single row (if they fit),
or in two equally-sized columns.

If you need more control over the layout of FormItem children,
you can use a container such as Grid or Tile as the direct child
of the FormItem and put the desired controls inside it.

The default value is FormItemDirection.VERTICAL.

This property can be used as the source for data binding. When this property is modified, it dispatches the directionChanged event.

Implementation public function get direction():String public function set direction(value:String):void

measure

Calculates the preferred, minimum and maximum sizes of the FormItem.
See the UIComponent.measure() method for more information
about the measure() method.

The FormItem.measure() method first determines
the number of columns to use.
If the direction property is
FormItemDirection.HORIZONTAL,
all controls will be placed in a single row if possible.
If the controls cannot fit in a single row, they are split
into two columns. If that does not work, then use
a single column. If direction is
FormItemDirection.VERTICAL, the controls are
placed in a single column (like VBox).

A FormItem contains two areas: the label area
and the controls area.
The size of the label is the same
regardless of the direction of the controls.
The size of the control area depends on how many rows
and columns are used.

The width of the label area is determined by the
labelWidth style property.
If this property is undefined (which is the default),
the width of the largest label in the parent Form container
is used.

If all children are on a single row, the width of the
control area is the sum of the widths of all the children
plus horizontalGap space between the children.

If the children are on a single column,
the width of the control area is the width of the widest child.

If the children are on multiple rows and columns,
the width of the widest child is the column width,
and the width of the control area is the column width
multiplied by the number of columns plus the
horizontalGap space between each column.

measuredWidth is set to the
width of the label area plus the width of the control area
plus the value of the indicatorGap style property.
The values of the paddingLeft and
paddingRight style properties
and the width of the border are also added.

measuredHeight is set to the
sum of the preferred heights of all rows of children,
plus verticalGap space between each child.
The paddingTop and paddingBottom
style properties and the height of the border are also added.

measuredMinWidth is set to the width of the
label area plus the minimum width of the control area
plus the value of the indicatorGap style property.
The values of the paddingLeft and
paddingRight style properties
and the width of the border are also added.

measuredMinHeight is set to the
sum of the minimum heights of all rows of children,
plus verticalGap space between each child.
The paddingTop and paddingBottom
style properties and the height of the border are also added.

updateDisplayList

Responds to size changes by setting the positions and sizes
of this container's children.
See the UIComponent.updateDisplayList() method
for more information about the updateDisplayList() method.

See the FormItem.measure() method for more
information on how the FormItem controls are positioned.

The label is aligned in the label area according to the textAlign style property.
All labels in a form are aligned with each other.

If the required property is true,
a symbol indicating the field is required is placed between
the label and the controls.

The controls are positioned in columns, as described in the
documentation for the measure() method.
The horizontalAlign style property
determines where the controls are placed horizontally.

When the direction property is
"vertical", any child that has no width
specified uses the measuredWidth rounded up
to the nearest 1/4 width of the control area.
This is done to avoid jagged right edges of controls.

This method calls the super.updateDisplayList()
method before doing anything else.

Parameters

unscaledWidth:Number — Specifies the width of the component, in pixels,
in the component's coordinates, regardless of the value of the
scaleX property of the component.

unscaledHeight:Number — Specifies the height of the component, in pixels,
in the component's coordinates, regardless of the value of the
scaleY property of the component.