public class FormConstraints extends Object implements Serializable
Modifier and Type | Field and Description |
---|---|
int |
column
Specifies the column where the component is to be placed.
|
double |
fillRightPct
Chooses when to right justify the component based on its stretchablity.
|
static int |
FREE_FIELD
Specifies that the field aligns to the right of the other fields in its
column.
|
static int |
FREE_LABEL
Specifies that the label aligns to the left of the other labels in its
column.
|
int |
height
Specifies the number of rows that the component spans.
|
Component |
label
Specifies the component or label to the right.
|
static int |
LABEL_ON_TOP
Specifies that the label aligns vertically with the field in the row
directly proceeding it.
|
int |
mode
Specifies the alignment for the compoent.
|
int |
row
Specifies the row where the component is to be placed.
|
Constructor and Description |
---|
FormConstraints()
Creates 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.
|
Modifier and Type | Method and Description |
---|---|
void |
setDefaults()
Sets the default values for all of the constraints.
|
public static final int FREE_LABEL
public static final int FREE_FIELD
public static final int LABEL_ON_TOP
public int row
public int column
public int height
public int mode
public double fillRightPct
public Component label
public FormConstraints()
public FormConstraints(int row, int col, int height, int mode, double fillRightPct, Component c)
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"Copyright © 2003, 2023, Oracle and/or its affiliates.