\Title{Formatting Information}
Total Page:16
File Type:pdf, Size:1020Kb
\title{formatting information} A beginner's introduction to typesetting with LATEX Peter Flynn Silmaril Consultants Textual Therapy Division v.3.4 November 2003 Acknowledgments Thanks to all the people who sent me corrections and suggestions for improvement or additions to earlier versions. As usual, the problem has been what to leave out, not what to include. Some of the suggestions were well-intentioned but would have turned the book into a higher-level mathematics treatise. One of my objectives was to omit all maths except for a short example, as all the other books on TEX and LATEX already cover mathematical typesetting in finer and better detail than I am capable of. Some of the suggestions would have taken me down pathways I prefer not to tread. Large software corporations are full of well-meaning, hard-working individuals who genuinely believe that their products make life easier for users. Unfortunately, experience shows that this is often only true in the first hot flush of using a new program: in the long run the winners are those whose data is secure, accessible, and reusable; whose documents can be reformatted at any time, on any platform, without penalty, financial or otherwise. I make no apology for recommending Unix-like systems running LATEX as the platform of choice for document-processing applications — if you have a choice — and I'm happy to be able to include the Apple Macintosh in that family. Unfortunately, there are those whose circumstances at home or work require them to use something else, and I am pleased that LATEX can help them by being available on their platform as well. I have incorporated all the remaining suggestions except where it would materially distort the objective of being a beginner's booklet. A special thank-you goes to Barbara Beeton, Karl Berry, and William Adams for their editorial corrections and contributions, finding all kinds of mistakes from simple slips of the finger to cultural differences to over-complicated ways of explaining things. It is very difficult for people who write technical documentation to remember how they struggled to learn what has now become a familiar system. So much of what we do is second nature, and a lot of it actually has nothing to do with the software, but more with the way in which we view and approach information, and the general level of knowledge of computing. If I have obscured something by making unreasonable assumptions about your knowledge, please let me know so that I can correct it. Peter Flynn is author of The HTML Handbook and Understanding SGML and XML Tools, and editor of The XML FAQ. Technical note The text for the March 2003 online edition was edited into a customized version of DocBook from the original private format (Read The Fine Markup Language (RTFML)). All subsequent work has been done in DocBook with a customization layer for typographics. XSLT was used to generate HTML (for the Web and plain-text versions) and LATEX (for PDF and PostScript). The November 2003 edition was published in TUGboat1. This document is Copyright © 1999, 2000, 2001, 2002, 2003 by Silmaril Consultants under the terms of what is now the GNU Free Documentation License (copyleft). Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is included in the section entitled The GNU Free Documentation License2. You are allowed to distribute, reproduce, and modify it without fee or further requirement for consent subject to the conditions in § A.4. The author has asserted his right to be identified as the author of this document. If you make useful modifications you are asked to inform the author so that the master copy can be updated. See the full text of the License in Appendix A. 1Beeton (Since 1980) 2FSF (2003/02/10 23:42:49) Contents Introduction . 120 Who needs this booklet? . 120 Skills needed . 120 Objectives of this booklet . 120 Synopsis . 121 Production note . 122 Foreword . 124 Preface . 125 1 Installing TEX 127 1.1 Editing and display . 127 1.2 Installation for Linux and Unix . 128 1.3 Installation for Apple Mac . 128 1.4 Installation for Microsoft Windows . 129 2 Using your editor to create documents 130 2.1 Quick start for the impatient . 130 2.2 Editors . 132 2.2.1 WinEdt . 132 2.2.2 GNU Emacs . 133 2.3 LATEX commands . 133 2.3.1 Simple commands . 134 2.3.2 Commands with arguments . 135 2.3.3 White-space in LATEX . 135 2.4 Special characters . 135 2.4.1 Using the special characters . 136 2.5 Quotation marks . 136 2.6 Accents . 137 2.7 Sizes, hyphenation, justification, and breaking . 138 2.7.1 Specifying size units . 139 2.7.2 Hyphenation . 140 2.7.3 Unbreakable text . 140 2.7.4 Dashes . 140 2.7.5 Justification . 140 2.7.6 Languages . 141 2.8 Mathematics . 141 3 Basic document structures 143 3.1 The Document Class Declaration . 143 3.1.1 Document class options . 144 3.2 The document environment . 145 3.3 Titling . 145 3.4 Abstracts and summaries . 147 3.5 Sections . 148 3.5.1 Section numbering . 149 3.6 Ordinary paragraphs . 150 3.7 Table of contents . 151 4 Typesetting, viewing and printing 153 4.1 Typesetting . 153 4.1.1 Standard LATEX . 153 4.1.2 pdfLATEX . 155 4.1.3 Running LATEX from a command window . 155 4.2 Error messages . 156 4.3 Screen preview . 157 4.3.1 Previewing DVI output . 157 4.3.2 Previewing with PDF . 158 4.3.3 Previewing with PostScript . 159 TUGboat Volume 23 (2002), No. 2 Formatting information 117 118 Formatting information TUGboat Volume 23 (2002), No. 2 4.4 Printer output . 159 5 CTAN, packages, and online help 161 5.1 Packages . 161 5.1.1 Using an existing package . 161 5.1.2 Package documentation . 162 5.2 Downloading and installing packages . 163 5.3 Online help . 165 6 Other document structures 166 6.1 A brief note on structure . 166 6.2 Lists . 167 6.2.1 Itemized lists . 168 6.2.2 Enumerated lists . 168 6.2.3 Description lists . 168 6.2.4 Inline lists . 169 6.2.5 Reference lists and segmented lists . 170 6.2.6 Lists within lists . 170 6.3 Tables . 171 6.3.1 Floats . 171 6.3.2 Formal tables . 172 6.3.3 Tabular matter . 172 6.3.4 Tabular techniques for alignment . 174 6.4 Figures . 175 6.5 Images . 175 6.6 Verbatim text . 177 6.6.1 Inline verbatim . 177 6.6.2 Display verbatim . ..