public class TableLayoutConstraints extends Object implements Serializable
We use the convention of specifying row before column to conform with the swing standards. This seems counterintuitive when specifying x,y (actually y,x) co-ordinates however we felt it was more important to conform to existing java layout standards.
Constructor and Description |
---|
TableLayoutConstraints(int row,
int column)
Create a new instance.
|
Modifier and Type | Method and Description |
---|---|
protected static void |
assertNotNull(String fieldName,
Object fieldValue)
Verify that the specified value is not null.
|
int |
getColumn()
Return the column.
|
int |
getColumnSpan()
Return the number of columns this component will span.
|
int |
getHorizontalAlignment()
Return the horizontalAlignment.
|
boolean |
getHorizontalStretch()
Return true if this component can be stretched horizontally.
|
boolean |
getObeyMaximumSize()
Return true if we are obeying the maximum size.
|
boolean |
getObeyMinimumSize()
Return true if we are obeying the minimum size.
|
int |
getRow()
Return the row.
|
int |
getRowSpan()
Return the number of rows this component will span.
|
int |
getVerticalAlignment()
Return the vertical alignment.
|
boolean |
getVerticalStretch()
Return true if this component can be stretched vertically.
|
boolean |
isImmutable()
Return true if this object is immutable.
|
static TableLayoutConstraints |
makeConstraints(String constraintString)
Create an instance of TableLayoutConstraints from the specified string.
|
void |
setColumn(int column)
Set the column.
|
void |
setColumnSpan(int span)
Set the number of columns that this component will span.
|
void |
setHorizontalAlignment(int alignment)
Set the horizontal alignment of the component within the specified
area.
|
void |
setHorizontalStretch(boolean stretch)
Set whether or not this component can be stretched horizontally.
|
void |
setImmutable()
Make this object immutable.
|
void |
setObeyMaximumSize(boolean obey)
Set whether or not the component should obey it's maximum size.
|
void |
setObeyMinimumSize(boolean obey)
Set whether or not we should obey the minimum size of the component.
|
void |
setRow(int row)
Set the row.
|
void |
setRowSpan(int span)
Set the number of rows that this component will span.
|
void |
setVerticalAlignment(int alignment)
Set the vertical alignment of the component within the specified area.
|
void |
setVerticalStretch(boolean stretch)
Set whether or not this component can be stretched vertically.
|
String |
toString()
Return a string representation of this object.
|
public TableLayoutConstraints(int row, int column)
row
- The starting row.column
- The starting column.public final String toString()
public final void setImmutable()
public final boolean isImmutable()
public final void setRow(int row)
row
- The row.public final int getRow()
public final void setColumn(int column)
column
- The new column.public final int getColumn()
public final void setRowSpan(int span)
span
- The new row span.public final int getRowSpan()
public final void setColumnSpan(int span)
span
- The new span.public final int getColumnSpan()
public final void setVerticalAlignment(int alignment)
alignment
- The new alignment.public final int getVerticalAlignment()
public final void setHorizontalAlignment(int alignment)
alignment
- The new alignment.public final int getHorizontalAlignment()
public final void setVerticalStretch(boolean stretch)
stretch
- true if the component will stretch vertically.public final boolean getVerticalStretch()
public final void setHorizontalStretch(boolean stretch)
stretch
- true if the component will stretch horizontally.public final boolean getHorizontalStretch()
public final void setObeyMaximumSize(boolean obey)
obey
- true if we are to obey the maximum size.public final boolean getObeyMaximumSize()
public final void setObeyMinimumSize(boolean obey)
obey
- true if we are to obey the minimum size.public final boolean getObeyMinimumSize()
public static TableLayoutConstraints makeConstraints(String constraintString)
constraintString
- The constraints string.protected static final void assertNotNull(String fieldName, Object fieldValue) throws DetailedNullPointerException
fieldName
- The name of the field to checkfieldValue
- The value of the field to checkDetailedNullPointerException
- If fieldValue is nullCopyright © 1998–2014 Gargoyle Software Inc.. All rights reserved.