The borderLayout component is a layout element that arranges its indexed children in the middle of a container, and supports the following named children, which arrange their child components in predefined, named areas:
bottom - Lays out children at the bottom of the
container, below the indexed children.
end - Lays out children in the same area as defined by
right. If the reading direction is from right to left, lays out
children in the same area as defined by left.
innerBottom - Lays out children below the indexed
children and above bottom children.
innerEnd - Lays out children in the same area as defined
by innerRight. If the reading direction is from right to
left, lays out children in the same area as defined by innerLeft
.
innerLeft - Lays out children between the left of indexed
children and the right of left children, and in between
top and bottom children.
innerRight -Lays out children between the right of
indexed children and the left of right children, and in
between top and bottom children.
innerStart - Lays out children in the same area as
defined by innerLeft. If the reading direction is from
right to left, lays out children in the same area as defined by
innerRight.
innerTop - Lays out children above the indexed children
and below top children.
left - Lays out children to the left of the indexed
children and in between top and bottom
children.
right - Lays out children to the right of the indexed
children and in between top and bottom
children.
start - Lays out children in the same area as defined by
left. If the reading direction is from right to left, lays out children
in the same area as defined by right.
top - Lays out children at the top of the container,
above the indexed children.
Notes:
right has
precedence over end when both end and
right are used. Similarly, left has precedence
over start when both start and left
are used. The same is true for innerEnd and innerRight
, and innerStart and innerLeft.
right has
precedence over start when both start and
right are used. Similarly, left has precedence over
end when both end and left are used.
The same is true for innerEnd and innerLeft,
and innerStart and innerRight.
Inserting a Component in a Named
Area Using BorderLayout
Inserting Indexed Children in a BorderLayout
Working with Layout Components
Copyright © 1997, 2004, Oracle. All rights reserved.