javax.rad.ui.layout
Interface IFormLayout.IAnchor

All Superinterfaces:
IResource
All Known Implementing Classes:
AwtFormLayout.AwtAnchor
Enclosing interface:
IFormLayout

public static interface IFormLayout.IAnchor
extends IResource

The Anchor gives the possible horizontal and vertical positions.


Field Summary
static int HORIZONTAL
          Constant for horizontal anchors.
static int VERTICAL
          Constant for vertical anchors.
 
Method Summary
 int getAbsolutePosition()
          Returns the absolute position of this Anchor in this FormLayout.
 IFormLayout.IAnchor getBorderAnchor()
          Gets the border anchor.
 IFormLayout getLayout()
          Returns the layout to which this anchor belongs.
 int getOrientation()
          Returns whether the orientation of this Anchor is HORIZONTAL or VERTICAL.
 int getPosition()
          Returns the position of this Anchor.
 IFormLayout.IAnchor getRelatedAnchor()
          Returns the related Anchor.
 float getRelativePosition()
          Returns the position of this Anchor.
 IFormLayout.IAnchor getSecondRelatedAnchor()
          Returns the second related Anchor.
 boolean isAutoSize()
          Returns true, if the position of this anchor is calculated automatically.
 void setAutoSize(boolean pAutoSize)
          Sets, if the position of this anchor is calculated automatically.
 void setPosition(int pPosition)
          Sets the position of this Anchor.
 void setRelativePosition(float pRelativePosition)
          Sets the position of this Anchor.
 
Methods inherited from interface javax.rad.ui.IResource
getResource
 

Field Detail

HORIZONTAL

static final int HORIZONTAL
Constant for horizontal anchors.

See Also:
Constant Field Values

VERTICAL

static final int VERTICAL
Constant for vertical anchors.

See Also:
Constant Field Values
Method Detail

getLayout

IFormLayout getLayout()
Returns the layout to which this anchor belongs.

Returns:
the orientation.

getOrientation

int getOrientation()
Returns whether the orientation of this Anchor is HORIZONTAL or VERTICAL.

Returns:
the orientation.

getRelatedAnchor

IFormLayout.IAnchor getRelatedAnchor()
Returns the related Anchor.

Returns:
the relatedAnchor.

getSecondRelatedAnchor

IFormLayout.IAnchor getSecondRelatedAnchor()
Returns the second related Anchor. If the second Anchor is not null the autosize and position has no effect. The position of the anchor is only calculated relative to the two related anchors.

Returns:
the secondRelatedAnchor.

getBorderAnchor

IFormLayout.IAnchor getBorderAnchor()
Gets the border anchor.

Returns:
the border anchor.

isAutoSize

boolean isAutoSize()
Returns true, if the position of this anchor is calculated automatically.

Returns:
the fixed.

setAutoSize

void setAutoSize(boolean pAutoSize)
Sets, if the position of this anchor is calculated automatically.

Parameters:
pAutoSize - the fixed to set.

getPosition

int getPosition()
Returns the position of this Anchor. The position is only correct if the layout is valid.

Returns:
the position.

setPosition

void setPosition(int pPosition)
Sets the position of this Anchor. It is not allowed to set the position of a border anchor.

Parameters:
pPosition - the position to set

getRelativePosition

float getRelativePosition()
Returns the position of this Anchor. The position is only correct if the layout is valid.

Returns:
the position.

setRelativePosition

void setRelativePosition(float pRelativePosition)
Sets the position of this Anchor. It is not allowed to set the position of a border anchor.

Parameters:
pRelativePosition - the relative position

getAbsolutePosition

int getAbsolutePosition()
Returns the absolute position of this Anchor in this FormLayout. The position is only correct if the layout is valid.

Returns:
the absolute position.


Copyright © 2009 SIB Visions GmbH. All Rights Reserved.