Day 10. Arranging Components on a User Interface

If designing a graphical user interface were comparable to painting, you could currently produce only one kind of art: abstract expressionism. You can put components onto an interface, but you don't have much control over where they go.

In order to impose some kind of form on an interface in Java, you must use a set of classes called layout managers.

Today you learn how to use five layout managers to arrange components into an interface. You'll take advantage of the flexibility of Swing, which was designed to be presentable on the many different platforms that support the language.

You also learn how to put several different layout managers to work on the same interface when one arrangement doesn't ...

Get Sams Teach Yourself Java 2 in 21 Days, Second Edition 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.