Chapter 4 Examples


 
Button Labels
ButtonLabels.java demonstrates the available button label alignments.
 
Button Text Postions
ButtonTextPos.java demonstrates the available button text positions.
 
Buttons
ButtonExample.java displays a number of buttons with various attributes. Images from the directory images are used.
 
Checkbox Example
CheckboxExample.java displays a number of checkboxes, some with icons, others with text. Images from the directory images are used.
 
RadioButton Example
RadioExample.java displays a number of radio button groups, some with icons, others with text. Images from the directory images are used.
 
ActionListeners
Actions.java demonstrates the techniques used to recieve notifications of action events. A window listener is used to handle the close box.
 
Mouse Listener
NoMice.java uses two custom components to demonstrate how to handle mouse events with listeners or by overriding the event processing methods. TargetPractice.java displays letters at the current mouse location using a mouse listener. Key events are handled by a KeyListener.


Copyright © 1998, John Wiley and Sons, Inc.