SOUTH
components (which are always displayed using their preferred height values)
causes those two components to overlap one another, as shown below:
Reducing the width of a container managed by a BorderLayout
initially causes the widths of the NORTH, CENTER,
and SOUTH components to become smaller until the
CENTER component eventually disappears completely. At that
point, reducing the container's width further causes the EAST
and WEST components to overlap:
Increasing the size of a BorderLayout-managed container
causes the CENTER component to become larger, and can
increase the widths of the NORTH and SOUTH
components and the heights of the EAST and WEST
components.
Container Size
The minimum size defined for a container managed by a
BorderLayout is calculated by calling the
getMinimumSize() method for all components in the container.
The minimum widths of the WEST, CENTER, and
EAST components are added together (if they are present)
along with the value needed to create a horizontal gap, and that sum is
treated as a single value. The value is then compared to the minimum width
of the NORTH component and the minimum width of the
SOUTH component, and the largest value of the three is chosen
as the container's minimum width. The minimum height of the container is
selected using a similar approach, but the sequence of steps is slightly
different. The minimum heights of the WEST,
CENTER, and EAST components are compared and the
largest of those three values is selected. It is then added to the minimum
height of the NORTH and SOUTH components along
with the space needed for vertical gaps and that value is used as the
container's minimum height.
The preferred size of a BorderLayout-managed container is
calculated using exactly the same approach described above, except that the
getPreferredSize() method is called for each component
instead of getMinimumSize() .
New on the Java Boutique:
New Review:
Time Management Made Easy with the Quartz Enterprise Job Scheduler
Why not just use the Java timer API? This open source scheduling
API boasts simplicity, ease-of-integration, a well-rounded feature
set, and it's free!
New Applet:
Reverse Complement
Reverse Complement is a simple applet that converts DNA or RNA
sequences into three useful formats.
Elsewhere on internet.com:
WebDeveloper Java
Lots of Java information on webdeveloper.com
WDVL Java
Thorough Java resource at the Web Developer's Virtual Library.
ScriptSearch Java
Hundreds of free Java code files to download.
jGuru: Your View of the Java Universe
Customizable portal with online training, FAQs, regular news updates, and tutorials.