Package com.portal.ctrl
Class FormConstraints
java.lang.Object
com.portal.ctrl.FormConstraints
- All Implemented Interfaces:
Serializable
Specifies the constriants for the components that are laid out using the
Form class.
- Author:
- Monica Gaines
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionint
Specifies the column where the component is to be placed.double
Chooses when to right justify the component based on its stretchablity.static final int
Specifies that the field aligns to the right of the other fields in its column.static final int
Specifies that the label aligns to the left of the other labels in its column.int
Specifies the number of rows that the component spans.Specifies the component or label to the right.static final int
Specifies that the label aligns vertically with the field in the row directly proceeding it.int
Specifies the alignment for the compoent.int
Specifies the row where the component is to be placed. -
Constructor Summary
ConstructorsConstructorDescriptionCreates a FormConstraints object with all values set to the defaults.FormConstraints
(int row, int col, int height, int mode, double fillRightPct, Component c) Creates a FormConstraints object with using the given values. -
Method Summary
Modifier and TypeMethodDescriptionvoid
Sets the default values for all of the constraints.
-
Field Details
-
FREE_LABEL
public static final int FREE_LABELSpecifies that the label aligns to the left of the other labels in its column.- See Also:
-
FREE_FIELD
public static final int FREE_FIELDSpecifies that the field aligns to the right of the other fields in its column.- See Also:
-
LABEL_ON_TOP
public static final int LABEL_ON_TOPSpecifies that the label aligns vertically with the field in the row directly proceeding it.- See Also:
-
row
public int rowSpecifies the row where the component is to be placed. -
column
public int columnSpecifies the column where the component is to be placed. -
height
public int heightSpecifies the number of rows that the component spans. -
mode
public int modeSpecifies the alignment for the compoent. Valid values are * -1, FREE_LABEL, FREE_FIELD, LABEL_ON_TOP. -
fillRightPct
public double fillRightPctChooses when to right justify the component based on its stretchablity. Stretchablity is the difference between a component's preferred and minimum widths. Valid values are -1, 0, 1, or between 0 and 1. -
label
Specifies the component or label to the right.
-
-
Constructor Details
-
FormConstraints
public FormConstraints()Creates a FormConstraints object with all values set to the defaults. -
FormConstraints
Creates a FormConstraints object with using the given values.- Parameters:
row
- the row to place the componentcol
- the column to place the compoentheight
- the number of rows the component spansmode
- the aligment for the componentfillRightPct
- the percentage for right justifcation of the compnentc
- the component to use as a "label"
-
-
Method Details
-
setDefaults
public void setDefaults()Sets the default values for all of the constraints.
-