mx.containers
Class FormItem



class FormItem
extends mx.containers.Container

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

MXML Syntax

The <mx:FormItem> container inherits all the properties of the Canvas class except marginLeft, and the following properties:

 <mx:FormItem
direction="vertical|horizontal"
horizontalAlign="left|center|right" horizontalGap="6"
indicatorGap="15">
label="No default."
labelWidth="Default value is calculated from width of the label text."
marginBottom="0"
marginRight="0"
marginTop="0"
required="false|true"
verticalGap="6"
...
child tags
...
/>

See Also
mx.containers.Form
mx.containers.FormHeading



Methods

Methods inherited from class mx.containers.Container
Constructor  getViewMetrics 

Methods inherited from class mx.core.View
init  draw  createChild  getChildAt  getChildIndex  setChildIndex  destroyAllChildren  destroyChild  destroyChildAt  getViewMetrics 

Methods inherited from class mx.core.UIComponent
getFocus  setFocus  getFocusManager 

Methods inherited from class mx.core.UIObject
createAccessibilityImplementation  measure  doLater  cancelAllDoLaters  invalidate  invalidateStyle  invalidateProperties  invalidateSize  redraw  move  setSize  setSizeNoLayout  drawRect  fillRect  destroyLabel  createClassObject  createEmptyObject  destroyObject  getStyle  setMask  swapDepths 


Properties
      direction:String   [Read/Write]
Direction of the children.
      labelObject:Object   [Read-Only]
Read-only property that lets you access the label of the FormItem container.
      required:Boolean   [Read/Write]
If true, the FormItem children require user input.

Properties inherited from class mx.containers.Container
version  className  numRepeaters  icon  autoLayout  defaultButton  childDescriptors  creationPolicy  clipContent  hScrollPolicy  vScrollPolicy  maxVPosition  maxHPosition  vLineScrollSize  hLineScrollSize  vPageScrollSize  hPageScrollSize  hPosition  vPosition 

Properties inherited from class mx.core.View
version  className  numChildren 

Properties inherited from class mx.core.UIComponent
version  enabled  tabIndex 

Properties inherited from class mx.core.UIObject
version  nestLevel  dispatchEvent  addEventListener  handleEvent  removeEventListener  kStretch  styleName  className  setStyle  parentApplication  isDocument  parentDocument  documentDescriptor  descriptor  instanceIndices  repeaterIndices  getRepeaterItem  id  width  height  x  y  minHeight  minWidth  preferredHeight  preferredWidth  maxHeight  maxWidth  widthFlex  heightFlex  visible  scaleX  scaleY  alpha  depth  mouseX  mouseY  toolTip  baselinePosition 


Effects

Effects inherited from class mx.core.UIComponent
showEffect  hideEffect  focusInEffect  focusOutEffect 

Effects inherited from class mx.core.UIObject
creationCompleteEffect  moveEffect  resizeEffect  mouseDownEffect  mouseOverEffect  mouseOutEffect  mouseUpEffect 


Events

Events inherited from class: mx.containers.Container
childrenCreated  scroll 

Events inherited from class: mx.core.View
childCreated  childIndexChanged  childDestroyed 

Events inherited from class: mx.core.UIComponent
focusIn  focusOut  keyDown  keyUp  show  hide  valid  invalid  valueCommitted 

Events inherited from class: mx.core.UIObject
initialize  creationComplete  resize  move  draw  load  unload  mouseDown  mouseUp  mouseMove  mouseOver  mouseOut  mouseDownSomewhere  mouseUpSomewhere  mouseMoveSomewhere  mouseChangeSomewhere  effectStart  effectEnd  dragBegin  dragComplete  dragEnter  dragOver  dragExit  dragDrop 


Styles
marginBottom Type: Number   Format: Length   CSS Inheritance: no
Number of pixels between the container`s bottom border and its content area. The default value is 0.
marginTop Type: Number   Format: Length   CSS Inheritance: no
Number of pixels between the container`s top border and its content area. The default value is 0.
marginRight Type: Number   Format: Length   CSS Inheritance: no
Number of pixels between the container`s right border and its content area. The default value is 0 pixels.
horizontalAlign CSS Inheritance: no
Horizontal alignment of children. The default is left. Possible values are left, center, and right.
horizontalGap Type: Number   Format: Length   CSS Inheritance: no
Number of pixels between children in the horizontal direction. The default value is 6.
verticalGap Type: Number   Format: Length   CSS Inheritance: no
Number of pixels between children in the vertical direction. The default is 6.
indicatorGap Type: Number   Format: Length   CSS Inheritance: yes
Number of pixels between the label and child components. The default value is 14.
labelWidth Type: Number   Format: Length   CSS Inheritance: yes
Width of the form labels. The default is the length of the longest label in the form.

Styles inherited from class mx.core.UIComponent
backgroundColor  backgroundDisabledColor  backgroundImage  backgroundAlpha  backgroundSize  barColor  borderCapColor  borderColor  buttonColor  borderStyle  disabledColor  errorColor  highlightColor  lineHeight  modalTransparency  scrollTrackColor  shadowColor  shadowCapColor  symbolColor  symbolBackgroundColor  symbolBackgroundDisabledColor  symbolBackgroundPressedColor  symbolDisabledColor  themeColor 

Styles inherited from class mx.core.UIObject
color  fontFamily  fontSize  fontStyle  fontWeight  textAlign  textDecoration  textIndent  marginLeft  marginRight  horizontalGap  verticalGap 


Property Detail

direction

direction:String   [Read/Write]

Direction of the children. Possible values are vertical, or horizontal. The default value is vertical.


labelObject

labelObject:Object   [Read-Only]

Read-only property that lets you access the label of the FormItem container.


required

required:Boolean   [Read/Write]

If true, the FormItem children require user input. If false, input is not required. The default is false.