Using the BorderLayout Manager

A border layout lays out a container, arranging and resizing its components to fit in five different regions: north, south, east, west, and center. Each region is identified by a corresponding constant contained within the class: NORTH, SOUTH, EAST, WEST, and CENTER. When adding a component to a container with a border layout, use one of these five constants, as shown in Figure 12.3.

Figure 12.3. BorderLayout showing the five different regions.

When to Use BorderLayout

You will probably use BorderLayout the most. Although it is not normally used alone, BorderLayout is normally used in conjunction with nested ...

Get Borland® JBuilder™ Developer’s Guide now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.