Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

org.modama.tools
Class ParameterLayout  view ParameterLayout download ParameterLayout.java

java.lang.Object
  extended byorg.modama.tools.ParameterLayout
All Implemented Interfaces:
java.awt.LayoutManager, java.awt.LayoutManager2

public class ParameterLayout
extends java.lang.Object
implements java.awt.LayoutManager2

Einfacher Layoutmanager, stellt Components untereinander dar, zu jedem Field sollte ein String übergeben werden, welcher als Label vor dem Field angezeigt wird die groese der rechten und linken seite kann angegeben werden, oder automatisch bestimmt werden (0 oder keine parameter uebergeben)


Field Summary
private  boolean autosizeleft
           
private  boolean autosizeright
           
private  int heightofallcomps
          the height of all the components
private  int left
           
private  java.awt.Container parent
           
private  float ratio
           
private  int right
           
 
Constructor Summary
ParameterLayout(java.awt.Container parent)
           
ParameterLayout(java.awt.Container parent, int left, int right)
           
 
Method Summary
 void addLayoutComponent(java.awt.Component comp, java.lang.Object constraints)
          Adds the specified component to the layout, with the specified constraints object.
 void addLayoutComponent(java.lang.String name, java.awt.Component comp)
          Adds the specified component to the layout group.
 float getLayoutAlignmentX(java.awt.Container target)
          Returns the alignment along the x axis.
 float getLayoutAlignmentY(java.awt.Container target)
          Returns the alignment along the y axis.
protected  java.awt.Dimension getLayoutSize(java.awt.Container parent)
           
 void invalidateLayout(java.awt.Container target)
          Invalidates the layout, indicating that if the layout manager has cached information it should be discarded.
 void layoutContainer(java.awt.Container parent)
          Lays out the components in the given container.
 java.awt.Dimension maximumLayoutSize(java.awt.Container target)
          Returns the maximum size of this component.
 java.awt.Dimension minimumLayoutSize(java.awt.Container parent)
          Calculates the minimum size for this container, taking into account the components it contains.
 java.awt.Dimension preferredLayoutSize(java.awt.Container parent)
          Calculates the preferred size for this container, taking into account the components it contains.
 void removeLayoutComponent(java.awt.Component comp)
          Removes the specified component from the layout group.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

left

private int left

right

private int right

ratio

private float ratio

parent

private java.awt.Container parent

autosizeright

private boolean autosizeright

autosizeleft

private boolean autosizeleft

heightofallcomps

private int heightofallcomps
the height of all the components

Constructor Detail

ParameterLayout

public ParameterLayout(java.awt.Container parent)

ParameterLayout

public ParameterLayout(java.awt.Container parent,
                       int left,
                       int right)
Method Detail

addLayoutComponent

public void addLayoutComponent(java.lang.String name,
                               java.awt.Component comp)
Description copied from interface: java.awt.LayoutManager
Adds the specified component to the layout group.

Specified by:
addLayoutComponent in interface java.awt.LayoutManager

removeLayoutComponent

public void removeLayoutComponent(java.awt.Component comp)
Description copied from interface: java.awt.LayoutManager
Removes the specified component from the layout group.

Specified by:
removeLayoutComponent in interface java.awt.LayoutManager

preferredLayoutSize

public java.awt.Dimension preferredLayoutSize(java.awt.Container parent)
Description copied from interface: java.awt.LayoutManager
Calculates the preferred size for this container, taking into account the components it contains.

Specified by:
preferredLayoutSize in interface java.awt.LayoutManager

minimumLayoutSize

public java.awt.Dimension minimumLayoutSize(java.awt.Container parent)
Description copied from interface: java.awt.LayoutManager
Calculates the minimum size for this container, taking into account the components it contains.

Specified by:
minimumLayoutSize in interface java.awt.LayoutManager

getLayoutSize

protected java.awt.Dimension getLayoutSize(java.awt.Container parent)

layoutContainer

public void layoutContainer(java.awt.Container parent)
Description copied from interface: java.awt.LayoutManager
Lays out the components in the given container.

Specified by:
layoutContainer in interface java.awt.LayoutManager

addLayoutComponent

public void addLayoutComponent(java.awt.Component comp,
                               java.lang.Object constraints)
Description copied from interface: java.awt.LayoutManager2
Adds the specified component to the layout, with the specified constraints object.

Specified by:
addLayoutComponent in interface java.awt.LayoutManager2

maximumLayoutSize

public java.awt.Dimension maximumLayoutSize(java.awt.Container target)
Returns the maximum size of this component.

Specified by:
maximumLayoutSize in interface java.awt.LayoutManager2

getLayoutAlignmentX

public float getLayoutAlignmentX(java.awt.Container target)
Returns the alignment along the x axis. This specifies how the component would like to be aligned relative to other components. The value should be a number between 0 and 1 where 0 represents alignment along the origin, 1 is aligned the furthest away from the origin, 0.5 is centered, etc.

Specified by:
getLayoutAlignmentX in interface java.awt.LayoutManager2

getLayoutAlignmentY

public float getLayoutAlignmentY(java.awt.Container target)
Returns the alignment along the y axis. This specifies how the component would like to be aligned relative to other components. The value should be a number between 0 and 1 where 0 represents alignment along the origin, 1 is aligned the furthest away from the origin, 0.5 is centered, etc.

Specified by:
getLayoutAlignmentY in interface java.awt.LayoutManager2

invalidateLayout

public void invalidateLayout(java.awt.Container target)
Invalidates the layout, indicating that if the layout manager has cached information it should be discarded.

Specified by:
invalidateLayout in interface java.awt.LayoutManager2