09.07.2015 Views

The Comprehensive LaTeX Symbol List

The Comprehensive LaTeX Symbol List

The Comprehensive LaTeX Symbol List

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

1428357676Figure 4: Proof diagram of lightbulb10.mfNow type a test command (\help for help):)*\table*\bye[1]Output written on testfont.dvi (1 page, 1516 bytes).Transcript written on testfont.log.<strong>The</strong> resulting table, stored in testfont.dvi and illustrated in Figure 5, shows every character in the font.To understand how to read the table, note that the character code for “A”—the only character defined bylightbulb10.mf—is 41 in hexadecimal (base 16) and 101 in octal (base 8).Test of lightbulb10 on March 11, 2003 at 1127´0 ´1 ´2 ´3 ´4 ´5 ´6 ´7´10x A´11x˝8 ˝9 ˝A ˝B ˝C ˝D ˝E ˝F˝4xFigure 5: Font table produced by testfont.tex<strong>The</strong> LightBulb10 font is now usable by TEX. L A TEX 2ε, however, needs more information before documentscan use the font. First, we create a font-description file that tells L A TEX 2ε how to map fonts in a given fontfamily and encoding to a particular font in a particular font size. For symbol fonts, this mapping is fairly simple.<strong>Symbol</strong> fonts almost always use the “U” (“Unknown”) font encoding and frequently occur in only one variant:normal weight and non-italicized. <strong>The</strong> filename for a font-description file important; it must be of the form“〈encoding〉〈family〉.fd”, where 〈encoding〉 is the lowercase version of the encoding name (typically “u” forsymbol fonts) and 〈family〉 is the name of the font family. For LightBulb10, let’s call this “bulb”. Figure 6 liststhe contents of ubulb.fd. <strong>The</strong> document “L A TEX 2ε Font Selection” [L A T00] describes \DeclareFontFamilyand \DeclareFontShape in detail, but the gist of ubulb.fd is first to declare a U-encoded version of the bulbfont family and then to specify that a L A TEX 2ε request for a U-encoded version of bulb with a (m)edium fontseries (as opposed to, e.g., bold) and a (n)ormal font shape (as opposed to, e.g., italic) should translate into aTEX request for lightbulb10.tfm mechanically scaled to the current font size.<strong>The</strong> final step is to write a L A TEX 2ε style file that defines a name for each symbol in the font. Becausewe have only one symbol our style file, lightbulb.sty (Figure 7), is rather trivial. Note that instead oftypesetting “A” we could have had \lightbulb typeset “\char65”, “\char"41”, or “\char’101” (respectively,decimal, hexadecimal, and octal character offsets into the font). For a simple, one-character symbol font98

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!