Now that you've learned how to establish a Swing GUI's look, it's time to consider its feel by using events and listeners. Caution Don't confuse this use of the phrase "look and feel" with the term PLAF. From a GUI building perspective, "look and feel" refers to the GUI design process. You've already seen examples of Swing's events and listeners. If you recall, the ColorChooserDemo source code (in Listing 16.3), demonstrated change events and a change listener to respond to selections from a color chart. Getting to know Swing's events and listeners involves studying the javax.swing.event package. You will also want to carefully review the SDK documentation, to learn what events are fired by each component. If you need additional examples, check out Sun's Java Tutorial at http://java.sun.com/docs/books/tutorial/. |