javax.rad.ui.layout
Interface IFormLayout

All Superinterfaces:
IAlignmentConstants, ILayout<IFormLayout.IConstraints>, IResource
All Known Implementing Classes:
AwtFormLayout, UIFormLayout

public interface IFormLayout
extends ILayout<IFormLayout.IConstraints>, IAlignmentConstants

Platform and technology independent form oriented layout definition. It is designed for use with AWT, Swing, SWT, JSP, JSF,... .


Nested Class Summary
static interface IFormLayout.IAnchor
          The Anchor gives the possible horizontal and vertical positions.
static interface IFormLayout.IConstraints
          The Constraint stores the top, left, bottom and right Anchor for layouting a component.
 
Field Summary
static String NEWLINE
          Constraint for starting a new row for the given component.
 
Fields inherited from interface javax.rad.ui.IAlignmentConstants
ALIGN_BOTTOM, ALIGN_CENTER, ALIGN_LEFT, ALIGN_RIGHT, ALIGN_STRETCH, ALIGN_TOP
 
Method Summary
 IFormLayout.IAnchor createAnchor(IFormLayout.IAnchor pRelatedAnchor)
          Constructs an anchor relative to pRelatedAnchor auto sized.
 IFormLayout.IAnchor createAnchor(IFormLayout.IAnchor pRelatedAnchor, IFormLayout.IAnchor pSecondRelatedAnchor, float pRelativePosition)
          Constructs an centered anchor between the related and second related anchor.
 IFormLayout.IAnchor createAnchor(IFormLayout.IAnchor pRelatedAnchor, int pPosition)
          Constructs an anchor relative to pRelatedAnchor with pPosition pixels.
 IFormLayout.IAnchor getBottomAnchor()
          Returns the bottom border anchor.
 IFormLayout.IAnchor getBottomMarginAnchor()
          Returns the bottom margin border anchor.
 IFormLayout.IConstraints getConstraints(IFormLayout.IAnchor pTopAnchor, IFormLayout.IAnchor pLeftAnchor, IFormLayout.IAnchor pBottomAnchor, IFormLayout.IAnchor pRightAnchor)
          Creates the default constraints for the given anchors.
 IFormLayout.IConstraints getConstraints(int pColumn, int pRow)
          Creates the default constraints for the given column and row.
 IFormLayout.IConstraints getConstraints(int pBeginColumn, int pBeginRow, int pEndColumn, int pEndRow)
          Creates the default constraints for the given column and row.
 IFormLayout.IAnchor[] getHorizontalAnchors()
          Returns all horizontal anchors used by this layout.
 IFormLayout.IAnchor getLeftAnchor()
          Returns the left border anchor.
 IFormLayout.IAnchor getLeftMarginAnchor()
          Returns the left margin border anchor.
 int getNewlineCount()
          Gets the new line count.
 IFormLayout.IAnchor getRightAnchor()
          Returns the right border anchor.
 IFormLayout.IAnchor getRightMarginAnchor()
          Returns the right margin border anchor.
 IFormLayout.IAnchor getTopAnchor()
          Returns the top border anchor.
 IFormLayout.IAnchor getTopMarginAnchor()
          Returns the top margin border anchor.
 IFormLayout.IAnchor[] getVerticalAnchors()
          Returns all vertical anchors used by this layout.
 void setNewlineCount(int pNewlineCount)
          Sets the new line count.
 
Methods inherited from interface javax.rad.ui.ILayout
getConstraints, getHorizontalGap, getMargins, getVerticalGap, setConstraints, setHorizontalGap, setMargins, setVerticalGap
 
Methods inherited from interface javax.rad.ui.IResource
getResource
 
Methods inherited from interface javax.rad.ui.IAlignmentConstants
getHorizontalAlignment, getVerticalAlignment, setHorizontalAlignment, setVerticalAlignment
 

Field Detail

NEWLINE

static final String NEWLINE
Constraint for starting a new row for the given component.

See Also:
Constant Field Values
Method Detail

getNewlineCount

int getNewlineCount()
Gets the new line count.

Returns:
the new line count.

setNewlineCount

void setNewlineCount(int pNewlineCount)
Sets the new line count.

Parameters:
pNewlineCount - the new line count.

createAnchor

IFormLayout.IAnchor createAnchor(IFormLayout.IAnchor pRelatedAnchor)
Constructs an anchor relative to pRelatedAnchor auto sized.

Parameters:
pRelatedAnchor - the related anchor for this anchor.
Returns:
the anchor.

createAnchor

IFormLayout.IAnchor createAnchor(IFormLayout.IAnchor pRelatedAnchor,
                                 int pPosition)
Constructs an anchor relative to pRelatedAnchor with pPosition pixels.

Parameters:
pRelatedAnchor - the related anchor for this anchor.
pPosition - the position relative to the related anchor.
Returns:
the anchor.

createAnchor

IFormLayout.IAnchor createAnchor(IFormLayout.IAnchor pRelatedAnchor,
                                 IFormLayout.IAnchor pSecondRelatedAnchor,
                                 float pRelativePosition)
Constructs an centered anchor between the related and second related anchor.

Parameters:
pRelatedAnchor - the related anchor for this anchor.
pSecondRelatedAnchor - the second related anchor for this anchor.
pRelativePosition - the relative position between first and second anchor.
Returns:
the anchor.

getLeftAnchor

IFormLayout.IAnchor getLeftAnchor()
Returns the left border anchor.

Returns:
the left border anchor.

getRightAnchor

IFormLayout.IAnchor getRightAnchor()
Returns the right border anchor.

Returns:
the right border anchor.

getTopAnchor

IFormLayout.IAnchor getTopAnchor()
Returns the top border anchor.

Returns:
the top border anchor.

getBottomAnchor

IFormLayout.IAnchor getBottomAnchor()
Returns the bottom border anchor.

Returns:
the bottom border anchor.

getLeftMarginAnchor

IFormLayout.IAnchor getLeftMarginAnchor()
Returns the left margin border anchor.

Returns:
the left margin border anchor.

getRightMarginAnchor

IFormLayout.IAnchor getRightMarginAnchor()
Returns the right margin border anchor.

Returns:
the right margin border anchor.

getTopMarginAnchor

IFormLayout.IAnchor getTopMarginAnchor()
Returns the top margin border anchor.

Returns:
the top margin border anchor.

getBottomMarginAnchor

IFormLayout.IAnchor getBottomMarginAnchor()
Returns the bottom margin border anchor.

Returns:
the bottom margin border anchor.

getHorizontalAnchors

IFormLayout.IAnchor[] getHorizontalAnchors()
Returns all horizontal anchors used by this layout.

Returns:
all horizontal anchors used by this layout.

getVerticalAnchors

IFormLayout.IAnchor[] getVerticalAnchors()
Returns all vertical anchors used by this layout.

Returns:
all vertical anchors used by this layout.

getConstraints

IFormLayout.IConstraints getConstraints(int pColumn,
                                        int pRow)
Creates the default constraints for the given column and row. Negative columns or rows counts the columns from the right or bottom border.

Parameters:
pColumn - the column.
pRow - the row.
Returns:
the constraints for the given column and row.

getConstraints

IFormLayout.IConstraints getConstraints(int pBeginColumn,
                                        int pBeginRow,
                                        int pEndColumn,
                                        int pEndRow)
Creates the default constraints for the given column and row.

Parameters:
pBeginColumn - the column.
pBeginRow - the row.
pEndColumn - the column count.
pEndRow - the row count.
Returns:
the constraints for the given column and row.

getConstraints

IFormLayout.IConstraints getConstraints(IFormLayout.IAnchor pTopAnchor,
                                        IFormLayout.IAnchor pLeftAnchor,
                                        IFormLayout.IAnchor pBottomAnchor,
                                        IFormLayout.IAnchor pRightAnchor)
Creates the default constraints for the given anchors.

Parameters:
pTopAnchor - the top anchor.
pLeftAnchor - the left anchor.
pBottomAnchor - the bottom anchor.
pRightAnchor - the right anchor.
Returns:
the constraints for the given Anchors.


Copyright © 2009 SIB Visions GmbH. All Rights Reserved.