testebook

Page 1

SamplePDFDocument RobertMaron GrzegorzGrudzi´nski February20,1999
2
Contents 1Template 5 1.1Howtocompilea .tex filetoa .pdf file ............. 5 1.1.1Tools ............................ 5 1.1.2Howtousethetools 5 1.2Howtowriteadocument 6 1.2.1Themaindocument 6 1.2.2Chapters .......................... 6 1.2.3Spell-checking ....................... 6 1.3LATEXandpdfLATEXcapabilities ................... 7 1.3.1Overview 7 1.3.2LATEX 7 1.3.3pdfLATEX 7 1.3.4Examples .......................... 7 3
4 CONTENTS

Chapter1 Template

1.1Howtocompilea

1.1.1Tools

Toprocessthefilesyou(may)need:

• pdflatex (forexamplefrom tetex package ≥ 0.9-6,whichyoucan getfrom RedHat5.2);

• acroread (aPDFviewer,availablefrom http://www.adobe.com/);

• ghostscript ≥ 5.10 (forexamplefromRedHatContrib)and ghostview or gv (fromRedHatLinux);

• efax packagecouldbeuseful,ifyouplantofaxdocuments.

1.1.2Howtousethetools

Followthesesteps:

1. putallsource .tex filesinonedirectory,thenchdirtothedirectory(orput someofthemintheLATEXsearchpath—ifyouknowhowtodothis);

2. run“pdflatexfile.tex”onthemainfileofthedocumentthreetimes (three—topreparevalidtableofcontents);

3. toseeorprinttheresultuse acroread (unfortunatelysomeversionsof acroread mayproducePostScriptwhichistoocomplex),or

.tex filetoa .pdf file
5

4. run ghostscript:“gvfile.pdf”todisplayor: “gs-dNOPAUSE-sDEVICE=pswrite-q-dBATCH-sOutputFile=file.psfile.pdf” toproduceaPostScriptfile;

5. run“faxsendphone-numberfile.ps”asroottosendafax,or—ifyou knowhowtodothis—modifythe fax scripttobeabletofax .pdf filesdirectly (youhavetoinsert“|%PDF*”somewhere...).

1.2Howtowriteadocument

1.2.1Themaindocument

Choosethenameofthedocument,say document.Copy template.tex to document.tex,theneditit,changethetitle,theauthorsandsetproperinclude(s)forallthechapters.

1.2.2Chapters

Eachchaptershouldbeincludedinthemaindocumentasaseparatefile.Youcan chooseanynameforthefile,butwesuggestaddingasuffixtothenameofthe mainfile.Forourexampleweusethefilename document_chapter1.tex.

First,copy template_chapter.tex to document_chapter1.tex andaddtheline

\include{document_chapter1}

inthe document.tex,thenedit document_chapter1.tex,changethe chaptertitleandeditthebodyofthechapterappropriately.

1.2.3Spell-checking

Do useaspell-checker,please!

Youmayalsowanttocheckgrammar,styleandsoon.Actuallyyoushould doit(ifyouhaveenoughsparetime).Butyou must checkspelling!

Youcanusethe ispell packageforthis,fromwithin emacs,orfromthe commandline:

ispell-tdocument_chapter1.tex

6
CHAPTER1.TEMPLATE

1.3.LATEXANDPDFLATEXCAPABILITIES 7

1.3LATEXandpdfLATEXcapabilities

1.3.1Overview

Firstyouedityoursource .tex file.InLATEXyoucompileitusingthe latex commandtoa .dvi file(whichstandsfordevice-independent).The .dvi file canbeconvertedtoanydevice-dependentformatyoulikeusinganappropriate driver,forexample dvips.

Whenproducing .pdf filesyoushoulduse pdflatex,whichproducesdirectly .pdf filesoutof .tex sources.Notethatinthe .tex fileyoumayneed tousesomePDFspecificpackages.

Forviewing .tex filesuseyourfavouritetexteditor,forviewing .dvi files underXWindowSystemuse xdvi command, .ps filescanbeviewedwith gv (or ghostview)and .pdf fileswith acroread, gv or xpdf

1.3.2LATEX

Alotofexamplescanbefoundinthisdocument. Youshouldalsoprint

• doc/latex/general/latex2e.dvi and

• doc/latex/general/lshort2e.dvi

fromyour tetex distribution(usuallyin

• /usr/share/texmf or

• /usr/lib/texmf/texmf).

1.3.3pdfLATEX

Consult doc/pdftex/manual.pdf fromyour tetex distributionformore details.Veryusefulinformationscanbefoundinthe hyperref and graphics packagemanuals:

• doc/latex/hyperref/manual.pdf and

• doc/latex/graphics/grfguide.dvi.

1.3.4Examples

References

MIMUW

Hyperlinks

Thisisatarget. Andthisisalink.

Dashes,etc.

Therearethreekindsofhorizontaldash:

• -(useinsidewords;forexample“home-page”,“X-rated”)

• –(usethisonebetweennumbers;forexample“pages2–22”)

• —(usethisoneasasentenceseparator—likehere)

Nationalcharacters

• ó,é,í,...

• è,à,ì,...

• ô,ê,...

• õ,ñ,...

• ö,ë,...

• ˙z

• ˛a,˛e

• ł,ø,ß

Thereareotherwaystodothis,seethedocumentationfor inputenc package.

Reservedcharacters

Somecharactershavesomespecialmeaning,thuscannotbeenteredintheusual way.

• $&%#_{} • \ • ˜ˆ

8 CHAPTER1.TEMPLATE

Formoreexamplesandsymbolsseechapter3of lshort2e.dvi.

Fonts

• Roman

• Emphasis

• Mediumweight—thedefault

• Boldface

• Upright

• Slanted

• Sansserif

• SMALLCAPS

• Typewriter

• andsizes: – tiny

scriptsize

footnotesize

small

normalsize

Math • 12 , 12n ,... • i1 , i2n,... • 1 2 , 2n 2 3 ,... • α, β, γ, Ω,... • → , ⇒, ≥, = , ∈, ,... • √2,... • 2+2,...
1.3.LATEXANDPDFLATEXCAPABILITIES 9

– large

– Large

– LARGE

– huge

– Huge

10
CHAPTER1.TEMPLATE

Turn static files into dynamic content formats.

Create a flipbook
Issuu converts static files into: digital portfolios, online yearbooks, online catalogs, digital photo albums and more. Sign up and create your flipbook.