Murach's Beginning Java 2, SDK 1.4

This chapter shows how to code a graphical user interface (GUI) that contains Swing components for labels, text boxes, and buttons. The next three chapters show how to use other Swing components such as combo boxes, list boxes, radio buttons, check boxes, and text areas.

Chapter 11 How to code a graphical user interface (part 1)
An introduction to the Swing classes 332
The user interface for the Loan Calculator application 332
The inheritance hierarchy 334
Methods of the Component class 336
How to work with frames 338
How to display a frame 338
How to close a frame 340
How to center a frame using the Toolkit class 342
How to work with panels, buttons, and events 344
How to add a panel to a frame 344
How to add buttons to a panel 346
How to handle button events 348
An introduction to layout managers 350
How to use the Flow layout manager 350
How to use the Border layout manager 352
How to structure the layout code 354
How to work with labels and text fields 356
How to work with labels 356
How to work with text fields 358
The Loan Calculator application 360
The user interface 360
The code 360
Perspective 366
t




Murach's Beginning Java 2

Learn more about this book

Add this book to your cart


See the Java 1.5 edition