All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class com.trumphurst.controls.PromptLayout

java.lang.Object
   |
   +----com.trumphurst.controls.TFlowLayout
           |
           +----com.trumphurst.controls.PromptLayout

public class PromptLayout
extends TFlowLayout
Prompt layout is used to layout input components and their prompt labels in a panel. It will Labels in a left column, and other components in a right column, lining the prompts up with their corresponding input components. The constructor has full control over alignment and packing within the columns.


Constructor Index

 o PromptLayout()
Constructs a new VFlow Layout with a LEFT, SPREAD alignment and a default 5-unit horizontal and vertical gap.
 o PromptLayout(int)
Constructs a new VFlow Layout with the specified alignment and a default 5-unit horizontal and vertical gap.
 o PromptLayout(int, int, int)
Constructs a new VFlow Layout with the specified alignment and gap values.

Method Index

 o layoutContainer(Container)
Lays out the container.
 o minimumLayoutSize(Container)
Returns the minimum dimensions needed to layout the components contained in the specified target container.
 o preferredLayoutSize(Container)
Returns the preferred dimensions for this layout given the components in the specified target container.

Constructors

 o PromptLayout
 public PromptLayout()
Constructs a new VFlow Layout with a LEFT, SPREAD alignment and a default 5-unit horizontal and vertical gap.

 o PromptLayout
 public PromptLayout(int align)
Constructs a new VFlow Layout with the specified alignment and a default 5-unit horizontal and vertical gap.

Parameters:
align - the alignment value
 o PromptLayout
 public PromptLayout(int align,
                     int hgap,
                     int vgap)
Constructs a new VFlow Layout with the specified alignment and gap values.

Parameters:
align - the alignment value
hgap - the horizontal gap variable
vgap - the vertical gap variable

Methods

 o preferredLayoutSize
 public Dimension preferredLayoutSize(Container target)
Returns the preferred dimensions for this layout given the components in the specified target container.

Parameters:
target - the component which needs to be laid out
Overrides:
preferredLayoutSize in class TFlowLayout
See Also:
Container, minimumLayoutSize
 o minimumLayoutSize
 public Dimension minimumLayoutSize(Container target)
Returns the minimum dimensions needed to layout the components contained in the specified target container.

Parameters:
target - the component which needs to be laid out
Overrides:
minimumLayoutSize in class TFlowLayout
See Also:
preferredLayoutSize
 o layoutContainer
 public void layoutContainer(Container target)
Lays out the container. This method will actually reshape the components in the target in order to satisfy the constraints of the PromptLayout object.

Parameters:
target - the specified component being laid out.
Overrides:
layoutContainer in class TFlowLayout
See Also:
Container

All Packages  Class Hierarchy  This Package  Previous  Next  Index