28.03.2013 Views

Guide to LaTeX (4th Edition) (Tools and Techniques

Guide to LaTeX (4th Edition) (Tools and Techniques

Guide to LaTeX (4th Edition) (Tools and Techniques

SHOW MORE
SHOW LESS

Create successful ePaper yourself

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

238 Chapter 10. PostScript <strong>and</strong> PDF<br />

10.2.3 The pdfT E X program<br />

The most direct method of getting PDF output is <strong>to</strong> process the L AT E X file<br />

with pdfT E X, a variation on the T E X program developed by Hàn Thê ´ Thành.<br />

The following points should be noted:<br />

• pdfT E X behaves just like the regular T E X program unless the declaration<br />

\pdfoutput=1 is issued before the first page is output; in this<br />

case, it generates PDF instead of DVI output <strong>and</strong> activates many new<br />

T E X-like comm<strong>and</strong>s for including PDF features.<br />

• Since pdfT E X combines the functionality of both the T E X program<br />

<strong>and</strong> a DVI driver, it must be able <strong>to</strong> deal with fonts in the way that a<br />

driver program would. Originally this meant that it could only h<strong>and</strong>le<br />

PostScript type 1 fonts, but now it can also cope with METAFONT<br />

bitmap fonts (type 3) as well as TrueType fonts. The bitmap fonts<br />

however look very bad when viewed, but this is a viewer problem.<br />

• When started, the program reads a configuration file pdftex.cfg<br />

which can set many parameters, as such page size, offsets, PDF<br />

compression level, <strong>and</strong> specifies the names of font mapping files.<br />

It may also set the default output <strong>to</strong> PDF, avoiding having <strong>to</strong> set<br />

\pdfoutput in the source text.<br />

• The font map files are identical <strong>to</strong> those used by dvips (page 236);<br />

they relate the T E X name for the font <strong>to</strong> various characteristics,<br />

encoding scheme, true name, <strong>and</strong> specify the file containing the<br />

character drawing instructions.<br />

• New T E X-like comm<strong>and</strong>s exist <strong>to</strong> include PDF features, like compression<br />

level, page attributes, document information, opening setup,<br />

forms, annotations, links, bookmarks, <strong>and</strong> article threads.<br />

• Graphics can be included in PNG, TIFF, or JPEG formats; PDF files<br />

may be inserted provided they contain only a single page without<br />

any fonts or bitmaps. The graphics packages (Section 6.1) support<br />

pdfT E X by means of a pdftex graphics option.<br />

To run pdfT E X with L AT E X (often referred <strong>to</strong> as pdfL AT E X), it is necessary<br />

<strong>to</strong> generate a L AT E X format (Section B.1.3) using pdfT E X instead of T E X, with<br />

the -ini option, renaming the resulting latex.fmt <strong>to</strong> pdflatex.fmt; it<br />

is then called with the comm<strong>and</strong><br />

pdftex &pdflatex<br />

Most installations contain a comm<strong>and</strong> pdflatex that translates <strong>to</strong> this<br />

combination. The edi<strong>to</strong>r shell should also have an icon that invokes this<br />

comm<strong>and</strong>.

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

Saved successfully!

Ooh no, something went wrong!