NextContents


QuickDraw GX typography


Introduction

QuickDraw GX provides typographic capabilities which match and even surpass the elegance and sophistication that characterized the era of metal type -- until now unattainable on desktop systems. Using TrueEdit, font developers can build a complete range of these typographic capabilities into their fonts, and allow any end user to produce typographically sophisticated output.

This chapter provides several kinds of background essential for getting the most out of TrueEdit. Before using TrueEdit to develop TrueType GX fonts, a font developer should be familiar with:

If you are already comfortable with these topics, you can begin learning about TrueEdit itself in the Introduction to TrueEdit.

The part of GX that is most important to readers of this manual is Line Layout, the collective name for the routines which provide high-quality typographic text automatically for GX applications. Line Layout works in conjunction with the typographic information contained in GX fonts to produce a variety of typographic effects.

The typographic effects appropriate for a particular GX font depend on the design and intended purpose of the font. To help TrueType GX font developers choose among the many options, Apple has developed a set of guidelines for "GX Savvy" Roman fonts. These guidelines have been distributed with developer releases of QuickDraw GX; the latest version is available from Apple Developer Support. The "GX Savvy" label will give end users, developers, and Apple a way to identify breakthrough products which set new standards for typographic functionality.

This section introduces the major kinds of typographic effects possible with a GX font. TrueEdit's support for each effect is discussed in detail in later chapters of this manual.

Glyph effects

QuickDraw GX and TrueType distinguish between characters and glyphs. Characters are elements of language, such as letters, numbers, and punctuation marks. Glyphs are the visual representations of characters. For example, there is one and only one character "a", the first letter of the Roman alphabet. But there are many different shapes that we recognize and interpret as "a". Some glyphs represent more than one character -- for example, the glyph "fi" represents "f" followed immediately by "i". Or there may be several alternate glyphs for a single character, as in the Arabic script.

Under QuickDraw GX, an end user enters characters into a line of text and Line Layout , working with information in the font, determines the appropriate glyphs to display. The application needs to be aware of characters only; QuickDraw GX handles all aspects of glyph display and output.

TrueType GX fonts can include more than 65,000 glyphs, along with information that tells Line Layout how and when to access each glyph. This manual uses the term glyph effects to refer to this information. A Roman font might include glyph effects for small caps, fractions, ligatures, superiors and inferiors, lowercase numerals, swash alternates, fleurons, borders, and other effects -- all in one font. For languages such as Hindi, certain kinds of glyph effects are essential for proper display.

The section Adding Glyph Effects describes how to use TrueEdit to add glyph effects to your font.

Position effects

A font's basic spacing, or metrics, defines the width and alignment of each glyph. QuickDraw GX provides a variety of features which extend the spacing capabilities of a font.

The term position effects encompasses all the information included in a GX font which determines the placement of glyphs relative to each other on a line. After Line Layout uses a font's glyph effects to determine which glyphs to display, it uses the position effects to determine their arrangement. Position effects can be applied to all glyphs in the font, or triggered by a specific context.

Kerning is a specific adjustment to the spacing of two or more adjacent glyphs; it is applied automatically under GX. Kerning information can be added to a GX font in several forms for flexibility. GX also allows cross-stream kerning, which moves glyphs perpendicularly to the reading direction of the text.

A related effect is optical alignment, which compensates for tricks of the human eye. Optical alignment adjusts each glyph's position at the beginning or end of a line of text, so the edge of the text block appears smooth and uniform.

Justification is the process of stretching or shrinking a line to force it to fit a certain width. QuickDraw GX fonts can contain information about how to justify a line by adjusting inter-glyph space, adjusting inter-word space, adding glyphs, replacing glyphs, or stretching glyphs -- dependent on the context and other information in the font. Periods and commas at the end of a line might be specified as hanging punctuation, which should be fixed outside the desired width.

Font-specific justification parameters are new with GX; previously, sophisticated justification has been the province of page layout applications. Line Layout uses the font's parameters under the application's overall control to ensure the best results.

Tracking is spacing adjustment which applies equally to all glyphs on a line. Type designers can define the tracking in GX fonts to allow optimal legibility of a typeface at any point size. This helps end users create consistently readable type, regardless of size -- even if they have never heard of tracking.

TrueEdit's tools for adding position effects are described in Adding Position Effects.

Language and script support

Throughout the world, different scripts lay out and align text in radically different ways. Reading direction can be right to left, left to right, or vertical. Some scripts depend on specific contextual forms for each glyph, while others rearrange glyphs depending on the context. QuickDraw GX makes it easy to combine multiple scripts in the same line -- even in the same font. Many of the features of TrueEdit are designed expressly to support these effects.

Some features are not new ideas with GX, but GX greatly expands on previous font capabilities. First, every font must have a character map, describing how to get from characters to glyphs; under GX, fonts can have multiple maps, each keyed to a different platform, script, or language. Vertically written GX fonts can contain vertical metrics information, equivalent to the horizontal metrics information used for scripts such as Roman. Embedded bitmaps can relieve the difficulty of creating instructions for very complex glyph designs.

New script features in GX include baselines, which govern the alignment of adjacent text in different scripts, and glyph properties, which Line Layout uses to resolve cases where two or more scripts run in different directions on a single line. So that a font may be used anywhere in the world on a GX system, localized names can be provided in any script or language available on the Macintosh.

These script and language features combine with glyph and position effects to support virtually any writing system. Which features are relevant to a particular font depends on the script or scripts it represents. For vertical scripts such as Mongolian, vertical metrics are essential. Arabic fonts require both right-to-left glyph properties and glyph effects for ligatures and contextual forms. For Hindi, a font can use glyph effects to reorder certain sequences. And for the Taliq script, which is written on rising diagonals, cross-stream kerning is necessary. Roman fonts can also use these capabilities to create useful and original effects.

TrueEdit's features are discussed in Adding Language and Script Support.

Style variations

QuickDraw GX dramatically expands the definition of type style. Where previously font developers and end users have been limited to regular, italic, bold, and bold italic, GX families can offer as many styles as the developer can create. With GX style variations, a single font can contain axes which define a range of styles, from light to bold, condensed to extended, or straight to wiggly. End users can choose any point along each axis and immediately see the effect on selected text. Style variations can also be used for new effects such as animated text and icons.

The Apple tool Mutator, described in the preface, is available for font developers interested in creating style variations. TrueEdit cannot create style variations.

[!]Although style variations are an important part of TrueType GX and GX typography, they are not covered in this manual.

Other capabilities

QuickDraw GX offers many new capabilities, so it is even more important for font developers to focus on creating a complete font package that works well for the end user.

No matter how much time and effort you put into building a font, no font exists alone. With so many options for effects and styles, it is important that a GX font be able to identify itself and its capabilities to the end user. GX fonts can achieve this through expanded name options, font descriptors (which let each font identify its own style), and other mechanisms.

A few additional steps are required to ensure your GX font is compatible with the systems and printers where it may be used. GX expands slightly on the existing TrueType requirements.

These areas are covered in Adding Other Tables, which also discusses TrueEdit's support for some TrueType capabilities which are unchanged for GX.


NextContents

Arleigh Movitz (movitz@apple.com)
Dave Opstad (opstad@apple.com)
Kristian Walsh (walsh.k@euro.apple.com)