O'Reilly logo

Special Edition Using Java 2 Standard Edition by Geoff Friesen, Chuck Cavaness, Brian Keeton

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Fonts and Colors

Fonts and colors are important attributes of JFC programs. Fonts give text an aesthetic quality and make it easier to read. Colors offer excitement and information. Without color, images would be dull and warning messages would be harder to convey. Because of their importance, Java simplifies the task of working with fonts and colors.

Getting to Know Fonts

Fonts are nothing more than sets of type. Each font has a size and face (style). Size is measured in points (units of type that are approximately 1/72 of an inch). Faces include Bold, Italic, Bold and Italic, or neither Bold nor Italic (Plain). When a program draws text, this text always appears in a specific font.

A font is given a face name that identifies its typographic ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required