public abstract class LayoutManager extends Object
| 构造器 | 说明 |
|---|---|
LayoutManager() |
Default constructor used to create a
LayoutManager instance. |
public LayoutManager()
LayoutManager instance.public void setOrientation(int orientation)
If you do not set the layout orientation, Component.VERTICAL is used by default.
orientation - Indicates the layout orientation to set. Component.HORIZONTAL
indicates that components are horizontally arranged,
Component.VERTICAL indicates that components are vertically
arranged.IllegalArgumentException - Throws the exception if the param values does not correspond to
Component.HORIZONTAL or
Component.VERTICAL.public int getOrientation()
Component.HORIZONTAL if components are horizontally arranged;
returns Component.VERTICAL if components are vertically arranged.