Chapter 6. Performing Custom Painting

http://java.sun.com/docs/books/tutorial/uiswing/14painting/index.html

You might not need to read this chapter at all. Many programs get by with no custom painting. If they display images, they do so using icons in standard Swing components such as labels and buttons. To display styled text, perhaps with embedded images and components, they use text components. To customize the edges of components, they use borders. To change the look of all components, they use a customizable look and feel, such as the GTK+ look and feel.

If you can't find a way to make a component look the way you want it to, then read on. This chapter introduces painting concepts, as they apply to Swing components, and then refers you elsewhere ...

Get JFC Swing Tutorial, The: A Guide to Constructing GUIs, 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.