站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > Java Tutorial 5.0 英文版

Working with Text and Fonts - Java Tutorial 5.0 英文版

The JavaTM Tutorial
Previous Page Lesson Contents Next Page Start of Tutorial > Start of Trail Search
Feedback Form

Trail: 2D Graphics

Lesson: Working with Text and Fonts

This lesson shows you how to determine what fonts are available on your system, create fonts with particular attributes, derive new fonts by modifying the attributes of an existing font, and position multi-line text within a component.

These topics are discussed in the following sections:

Creating and Deriving Fonts

This section illustrates how to use the GraphicsEnvironment to determine what fonts are available on your system, how to create a Font object and to how to change the font attributes of a text string.

Drawing Multiple Lines of Text

This section shows you how to position and render a paragraph of styled text using TextLayout and LineBreakMeasurer.

Previous Page Lesson Contents Next Page Start of Tutorial > Start of Trail Search
Feedback Form

Copyright 1995-2005 Sun Microsystems, Inc. All rights reserved.