13.1. PostScript Hints

In this section we shall examine hinting, which is the placement of hints in PostScript Type 1 or CFF fonts. In Figure 13-1, the reader can compare the same text in various rasterizations, three of them optimized with hints in different ways and one not optimized at all.

There are two types of PostScript hints: global hints, which affect the entire font, and individual hints, which affect only a single glyph.

13.1.1. Global PostScript Hints

Of the global hints, two are very important: the alignment zones (i.e., the relevant heights and the overshoots that go with them) and the relevant stroke thicknesses (see §C.3.4.1-C.3.4.3). Some examples are shown in Figure 13-2. Thus it is necessary to "take inventory" of the alignment zones and the stroke thicknesses that seem relevant: for a Latin font, these are more or less classic; for another font, these must be determined by taking measurements and trying to observe similarities and analogies. We shall see how Font-Lab and FontForge can help us to identify the most relevant values.

Figure 13-1. A comparison of various optimizations of the rasterization of a PostScript Type 1 font. The font is Monotype Old Style. Left: as rasterized by freetype with gray levels. Right: without gray levels. ① The font's original hints. ② The font without hints. ③ The hints generated by FontForge. ④ The hints generated by FontLab. The text is from Goethe: "Ye wavering shapes, again ye do enfold me / As erst upon my troubled sight ...

Get Fonts & Encodings 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.