1
2
3\startcomponent fontsintroduction
4
5\environment fontsenvironment
6
7\startchapter[title=Introduction][color=darkgray]
8
9You sit in a cave and wonder how to keep track of your winter stock. While
10playing with some burned wood you end up with vertical strokes on the wall
11representing how much you have in store.
12
13You walk through the woods and wonder how to find your way back. Suddenly it
14strikes you that you can put markers on trees. Years from that moment the whole
15forest is marked with routes. Different symbols carry different meanings.
16
17The next thing you want to do is to carry around information and pass it onto
18following generations. So, you turn those symbols into shapes that make up the
19scripts that can be used to express your languages in.
20
21For ages scripts have evolved and the rendering of them on stone or wood and
22later paper has resulted in a multitude of coherent collections of so called
23glyphs. Manual labour turned into (semi) automated mass production and once that
24took off, developments went fast. But the quality was still somewhat dubious,
25especially when for instance specialized scripts like math had to be dealt with.
26
27Some 30 years ago Don Knuth wrote a book, and in the process invented the \TEX\
28typesetting system, the graphical language \METAFONT\ and a bunch of fonts. He
29made it open and free of charge. He was well aware that the new ideas were built
30on older ones that had evolved from common sense: how to keep track of things on
31paper.
32
33It is no surprise that an active community formed around these goodies. First of
34all the system has no strings attached: the licence is generous and there are no
35patents involved. There is also a network of user groups that takes care of
36coordinated updates to the whole machinery. Of course it helps that it all
37relates to Don Knuth.
38
39Since \TEX\ showed up several open and closed source typesetting systems have
40surfaced and only some of them survived. Also regular word processing has become
41more clever and still become better. The \TEX\ typesetting system also moved on.
42Some of its ideas have been used in other programs and some of the ideas of other
43programs made their way into \TEX. However, its main property is still there: you
44can tweak and tune it to your needs and are not hampered by too many limitations.
45
46Don Knuth had this chicken or egg problem: once you can typeset a source you need
47fonts but you can only make fonts if you can use them in a typesetting program.
48As a result \TEX\ came with its own fonts and it has special ways to deal with
49them. Given the limitations of that time \TEX\ puts some limitations on fonts and
50also expects them to have certain properties, something that is most noticeable
51in math fonts.
52
53Rather soon from the start it has been possible to use third party fonts in \TEX,
54for instance \TYPEONE. As \TEX\ only needs some information about the shapes, it
55was the backend that integrated the font resources in the final document. One of
56its descendants, \PDFTEX, had this backend built in and could do some more clever
57things with fonts in the typesetting process, like protrusion and expansion. The
58integration of front and backend made live much easier. Another descendant,
59\XETEX\ made it possible to move on to the often large \OPENTYPE\ fonts. On the
60one hand this made live even more easy but at the other end it introduced users
61to the characteristics of such fonts and making the right choices, i.e.\ not fall
62in the trap of too fancy font usage.
63
64In this manual we will look at fonts from the perspective of yet another
65descendant, \LUATEX. It inherits the font technology from traditional \TEX, but
66also extends it so that we can deal with modern font technologies. Of course it
67offers much more, but in practice much relates to fonts one way or the other.
68
69Of course this exploration will be from the perspective of the \CONTEXT\ macro
70package but this is not a manual about how to use fonts in \CONTEXT\ as we have
71another manual for that. Much of what we say here applies to the generic font
72code as well, although some more advanced control is \CONTEXT\ specific. There is
73nothing real new here, and it all evolved from common sense and dealing with
74\TEX\ for many years. The perspective is mostly that of being a user myself so
75dont complain too loudly if things look complicated and unclear.
76
77There is some overlap between the chapters. This is because each chapter is
78written from another perspective and this document quite certainly will not be
79read as a whole but more by looking at examples.
80
81\startnotabene
82 This document will probably have an \quote {still under construction} state
83 for a long time. The functionality discussed here will stay and more might
84 show up. Of course there are errors, and theyre all mine.
85\stopnotabene
86
87\startlines
88Hans Hagen
89PRAGMA ADE, Hasselt NL
90Summer 2011 \endash\ Spring 2016
91\stoplines
92
93\stopchapter
94
95\stopcomponent
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115 |