Working with Layouts
Recall that several of the sample applets shown in Chapter 36 use layout managers such as CardLayout or GridLayout to manage the placement of components on the screen. You can see the effect of a layout manager by resizing the HelloPlus window. Figure 37.6 shows a maximized window in which the components have room to spread out; in Figure 37.7, the window is tall and narrow—the components appear one above the other.
Figure 37.6. When the components have enough room, they're laid out one beside the other.
Figure 37.7. When the window is narrow, the components flow one above the next.
You don't have to worry about the precise ...
Get Platinum Edition Using XHTML™, XML, and Java™ 2 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.