Skip to main content


com.sun.lwuit.layouts
Class BoxLayout

java.lang.Object
  
extended by com.sun.lwuit.layouts.Layout extended by com.sun.lwuit.layouts.BoxLayout
public class BoxLayout
extends Layout

Layout manager that places elements in a row or column according to box orientation


Field Summary
static int X_AXIS
          Horizontal layout where components are arranged from left to right
static int Y_AXIS
          Vertical layout where components are arranged from top to bottom
 
Constructor Summary
BoxLayout(int axis)
          Creates a new instance of BoxLayout
 
Method Summary
 boolean equals(java.lang.Object o)
           
 int getAxis()
          Returns the layout axis x/y
 Dimension getPreferredSize(Container parent)
          Returns the container preferred size
 void layoutContainer(Container parent)
          Layout the given parent container children
 java.lang.String toString()
           
 
Methods inherited from class com.sun.lwuit.layouts.Layout
addLayoutComponent, getComponentConstraint, hashCode, isOverlapSupported, removeLayoutComponent
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

X_AXIS

public static final int X_AXIS
Horizontal layout where components are arranged from left to right

See Also:
Constant Field Values

Y_AXIS

public static final int Y_AXIS
Vertical layout where components are arranged from top to bottom

See Also:
Constant Field Values
Constructor Detail

BoxLayout

public BoxLayout(int axis)
Creates a new instance of BoxLayout

Parameters:
axis - the axis to lay out components along. Can be: BoxLayout.X_AXIS or BoxLayout.Y_AXIS
Method Detail

layoutContainer

public void layoutContainer(Container parent)
Description copied from class: Layout
Layout the given parent container children

Specified by:
layoutContainer in class Layout
Parameters:
parent - the given parent container

getPreferredSize

public Dimension getPreferredSize(Container parent)
Description copied from class: Layout
Returns the container preferred size

Specified by:
getPreferredSize in class Layout
Parameters:
parent - the parent container
Returns:
the container preferred size

getAxis

public int getAxis()
Returns the layout axis x/y

Returns:
the layout axis

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class Layout


Copyright 2011 Oracle Corporation. All rights reserved. Use is subject to license terms.
 
 
Close
loading
Please Confirm
Close