1 #LyX 1.3 created this file. For more info see http://www.lyx.org/
11 \paperfontsize default
18 \use_numerical_citations 0
19 \paperorientation portrait
22 \paragraph_separation indent
24 \quotes_language english
28 \paperpagestyle default
32 Using different fonts in LyX
67 yX currently uses a fairly limited selection of fonts.
68 While it may come as a disappointment to people used to the thousands of
69 TrueType fonts available to conventional word processors, there are in
70 fact good reasons for this choice.
71 LyX actually has no fonts of its own; for the screen it uses whatever fonts
72 are available to the X-window system, and for output it uses the fonts
73 of the TeX setup it is operating with.
74 The selection of default faults correspond to the most useful and commonly-foun
75 d fonts available in TeX.
77 \begin_inset Quotes eld
81 \begin_inset Quotes erd
84 at the beginning of this section is a case in point: most TeX distributions
89 font, so you should see a nice decorated
90 \begin_inset Quotes eld
94 \begin_inset Quotes erd
97 at the beginning; some distributions may not, so you won't.
100 Another point is that the profusion of fonts which TrueType brought about
101 has generally had a bad effect on desktop publishing, leading to documents
102 with inappropriate, badly-scaled or simply too many fonts.
103 You should therefore think carefully before using a different default font,
104 or mixing font families in the same document.
107 Nevertheless, you can, with a little Evil Red Text, make LyX produce just
108 about any font you want, and even design your own fonts.
110 \begin_inset Quotes eld
116 \begin_inset Quotes erd
121 guide; it is no substitute for reading a good book on (La)TeX.
122 \layout Subsubsection
124 Changing the default font
127 The easiest and most reliable way to change the default font is from within
130 Layout\SpecialChar \menuseparator
131 Document\SpecialChar \menuseparator
135 The next easiest is to use a package contained in your TeX distribution.
136 For example, the rather pretty Pandora font family can be accessed simply
143 in your LaTeX preamble (
145 Layout\SpecialChar \menuseparator
172 in the preamble gives you access to Yannis Haralambous' Old German (Gothisch)
173 fonts via the specially-defined
191 commands, which you insert in your document (as TeX) to obtain the desired
192 font (note that nothing will change in your screen display, which considering
193 the difficulty involved in reading some of these fonts is just as well).
194 Other useful packages are
198 , which gives access to both the Concrete Roman and the Euler math fonts,
203 , which gives you the Zapf Chancery font
206 A less reliable method is the
213 If you have a font installed and know its family name, you can put something
227 \begin_inset Quotes eld
231 \begin_inset Quotes erd
234 is the family name for the Zapf Chancery font).
235 You should be aware, however, that this method may produce strange results
236 if the font you have selected does not have the sizes or shapes you want
237 (e.g., adding emphasis to text has no effect on Zapf Chancery, and choosing
238 the sans serif or typewriter series will cause it to revert to the standard
240 \layout Subsubsection
242 More than one font family in one document
245 As I've said, different font families in the same document can spell trouble.
246 Unlike many human families, the members of a font family work well together,
247 so the eye is not overly disturbed when changing from a medium roman to
248 a bold sans serif font, for example.
249 Different font families may not have this visual compatibility, and clashing
250 fonts are a common reason for amateur publishing looking amateurish.
254 Nevertheless, you may need different fonts for some reason: maybe you have
255 to include a different alphabet, like Klingon or Cuneiform
261 These can be downloaded from CTAN.
262 Remember, though, that some
263 \begin_inset Quotes eld
267 \begin_inset Quotes erd
270 fonts can be turned into a different alphabet by changing the font encoding;
271 see a good LaTeX book if you want to do this.
274 , or you want a structural/aesthetic effect, such as putting poetry in a
275 different font from prose, like this:
295 Myself when young did eagerly frequent
297 Emacs and vi, and heard great Argument
310 One way to do this is to declare your own font commands.
323 will define a command,
329 , which can be invoked anywhere in your document to change to the
354 You can return to your default font by typing
363 Some fonts will perform adequately with just the basic font name (as above);
364 others require that you specify a font size; for example, the verse above,
365 aside from mangling Omar Khayyam, used the font command
373 Some fonts may also need scaling using the
382 option, since their idea of, say, 10pt, may not be the same as that of
383 your default font family.
384 If the font looks too small, try a command like this:
396 This scales the rather small-looking Zapf Chancery font so that it looks
397 the same size as the default (10pt) font.
398 If your font looks too big, select a smaller fontsize (e.g., 8pt) and scale
400 \layout Subsubsection
405 So where do you find all these exciting new fonts? There are three main
409 Look around in your TeX distribution.
415 Convert TrueType fonts to TeX.
418 The first stage is as far as most people will want to go.
425 to see what you've got (where
429 is the location of your TeX system, usually something like
434 When you see something that looks promising, test it in a LyX document
435 using the method described above, i.e.
436 make a new font command and use it on some text, then preview and see what,
437 if anything, you get.
438 Note that the font name you want is usually the first four letters of the
439 file name, e.g., a file named
443 is actually the bold (b) version of Adobe's (p) New Century (nc) family.
444 If in doubt about names, check out the files in
451 TeX fonts can be downloaded from your nearest CTAN mirror (e.g.,
452 \begin_inset LatexCommand \url{ftp.ivorytower.edu/pub/tex/ctan/fonts}
457 At first, look for font directories which include a
461 file which you can invoked in your preamble, as this will make life easier
462 (as in the case of Pandora).
463 Failing that, look for directories which give you the full set of TeX font
473 file and run the program
477 on it (read, or at least skim, the manual first---you've probably got it
480 $TEXMF/doc/fontinst/base/fontinst.dvi
486 If all you have is an
490 file, you need to run
514 on it., which is beyond the scope of this guide: read
550 You should now have a directory filled with downloaded or converted files;
551 now you need to put the font files in the right places.
552 Unless you're running Windows 9* or have an entire TeX system in your home
553 directory, you need to be root to do this.
554 The basic rule is to look at the extension of the file and move it to the
555 corresponding directory, and put
573 \begin_inset Formula $\rightarrow$
592 \begin_inset Formula $\rightarrow$
607 These will be documentation files for the font, not fonts themselves.
616 \begin_inset Formula $\rightarrow$
637 \begin_inset Formula $\rightarrow$
658 \begin_inset Formula $\rightarrow$
679 \begin_inset Formula $\rightarrow$
700 \begin_inset Formula $\rightarrow$
703 $TEXMF/fonts/truetype/
718 If this sounds confusing, check out
719 \begin_inset LatexCommand \url{http://www.ctan.org/installationadvice/}
726 Thought you were finished? Not quite.
727 First you need to hack the file
729 $TEX/dvips/base/psfonts.map (
731 there is a script to do this in a more orderly manner if you want---look
732 at the comments at the top of the file for details).
738 If you don't want to, or can't change the system-wide font map, you can
743 file in your home directory which will add your own font lines.
751 You need to add a line describing your new font so that
756 Look at the other lines to get an idea of the format.
792 If you're not sure what to write here, run
800 file, and enter what comes up in the terminal.
809 (as root, of course), or
811 initexmf\SpecialChar ~
814 , if you're using MikTeX on Windows.
817 If that wasn't enough for you, you may want to try converting your favourite
818 TrueType font into a form that LyX can get at.
819 It's a long, tiring process, but if you really want that font, it's worth
821 First download the program
825 , run it on your font, then run
829 on the output, and proceed as before.
831 \begin_inset LatexCommand \url{http://www.pegasus.rutgers.edu/~elflord/unix/latex/no-bs.html}
837 \layout Subsubsection
839 Making your own fonts
842 There are (at least) three ways to do this.
848 Set aside some time---maybe a summer vacation.
899 Produce beautiful fonts.
905 Get a TrueType font editor.
906 Make a TrueType font.
908 This may work, but may produce rather ugly results.
914 If all you want is a few words (e.g., for a heading), rather than making an
915 entire font, write want you want by hand and scan it, then insert it as
917 You could in theory make a whole alphabet like this and insert each letter
922 file, but it would be tedious, and probably not very aesthetic.
923 \layout Subsubsection
928 For a good overview of fonts in LaTeX:
930 \added_space_bottom smallskip \noindent
931 Michel Goossens, Frank Mittelbach and Alexander Samarin:
939 For more technical information about fonts and some samples:
941 \added_space_bottom smallskip \noindent
949 \added_space_bottom smallskip \noindent
950 If you really, really want to design fonts:
952 \added_space_bottom smallskip \noindent
958 Addison Wesley, 1986.