Read Me First

Download as pdf or txt
Download as pdf or txt
You are on page 1of 9

Read Me First

November 4, 2009

Contents
1 2 3 4 5 6 7 8 Conguring MacTEX TeXShop and TeXworks First Steps with TEX Second Steps with TEX MacTEX for Experts TEX Live Documentation Spell Checking Conguring on 10.3 1 2 2 5 6 7 8 8

Conguring MacTEX

If you are running system 10.4 or higher, you are ready to go. If you are running system 10.3, skip to the end of this document for a brief conguration step.

TeXShop and TeXworks

TEX is a typesetting program, originally designed for mathematical and scientic documents, but increasingly used in other elds as well. The MacTEX distribution contains the TEX program and a large number of support les: fonts, style les, class elds, and so forth. Most of these les remain hidden from the user, who interacts with TEX via a front end. This front end contains an editor used to enter source text, and a preview window showing the typeset output. After installation of MacTEX, your /Applications/TeX folder will contain two front ends to TEX TeXShop and TeXworks. TeXShop has been available for OS X since the introduction of the operating system; TeXworks is a new front end modeled on TeXShop but available for many computer platforms: OS X, Windows, Linux, etc. The two programs have the same design, so a user familiar with one can immediately use the other.

First Steps with TEX

If you are new to TEX, the following steps will get you started. Go to /Applications/TeX and nd TeXShop. Drag its icon to your dock. Run the program. You will be presented with a blank window; at the top right of this window youll nd a pull down menu named Templates. From this menu choose LaTeX Template. The blank window will ll with some standard boilerplate required in each TEX source le. The red lines are comments which TEX ignores. New material goes between the lines
\begin{document}

and
\end{document}

Type some sentences there now. TEX will ignore most carriage returns because it knows how to format text, so insert them randomly if you wish. Use a blank line to indicate the start of a new paragraph. Uncomment the source line with the words usepackage[parll]parskip if you prefer to separate paragraphs with an empty line instead of an indent.

Figure 1: Edit Window

When you have some material, hit the Typeset button at the top left of the window. A dialog will appear asking you to save the document. When TEX typesets, it creates three or four additional les, so it is not a good idea to save directly to a location with many other les. Instead, put your source in a folder within such a location. To do that, navigate to a reasonable location, say ~/Documents, and then hit the New Folder button at the bottom of the dialog. Accept the default name or choose another and create the folder. Then name the document and save it. The default Untitled name will do. As soon as you save, TEX will typeset the document and open a second window showing the result.

Figure 2: Typeset Window Go back to the original window and add some additional text. Hit Typeset again. This time TEX immediately typesets the new material and updates the output window. 4

Now quit the program. It is possible to reopen the project by double clicking on the Untitled le or by starting TeXShop and navigating to Untitled in the Open dialog, but there is a much easier way. Start TeXShop and under the File menu choose the item Open Recent... In the resulting list, choose Untitled and you will immediately return to the document. Those are the basics. You will nd further information in the TeXShop Help menu. The rst short item, First Steps With TeXShop, should tell you everything you need to know to get started. Go to the Help menu now and select the submenu TeXShop Demos and then the item Getting Started. Youll be shown a movie illustrating the steps you just performed. You may be unhappy with TeXShops placement of the two crucial windows. This is easily xed, as explained in the second movie Initial Preferences. Watch that movie and follow the suggestions in it to rationalize placement of the windows.

Second Steps with TEX

The next crucial step is to learn TEX. George Grtzer gave permission to put the rst aE portion of his book More Math Into L T X in the TeXShop Help window, so begin by reading that document. It is also a good idea to read some of the material on the MacTEX web site: http://www. tug.org/mactex. The link References at the top of this page leads to a particularly useful page, http://www.tug.org/mactex/references, which has a lot of information about learning TEX. In particular, several useful online tutorials are available. If you are serious about TEX, youll probably want to buy some books. Visit http://tug.org/books/ for an excellent list of classics, available at a discount with free shipping. The following locations may prove useful: TeX Wiki by Gary Gray, Joseph Slater, and others:
http://mactex-wiki.tug.org

Information on joining the TEX on Mac OS X mailing list:


http://mactex-wiki.tug.org/wiki/index.php?title=Mailing_Lists

a For specialized versions of TEX and LTEX see:

a Information on XETEX and XELTEX:


http://scripts.sil.org/xetex

Information on ConTEXt:
http://www.pragma-ade.com

MacTEX is brought you by the TeX user groups across the world, including the one for English speakers: TEX Users Group Site:
http://www.tug.org

Searching this site will reveal a vast reservoir of information, including A Short History of TEX:
http://www.tug.org/whatis.html

A free online journal focused on practical use:


http://www.tug.org/pracjourn/

Archived issues of the main journal about TEX:


http://www.tug.org/TUGboat/

Information on joining TUG, to get the latest issues and much more: http://www.tug.org/join.html. See also
http://www.tug.org/usergroups.html

for a list of other user groups; please join the one best for you! The Comprehensive TEX Archive Network (CTAN):
http://www.ctan.org/

TeXShop is just one of the many available editors and previewers for TEX on OS X. After you are comfortable with TEX, youll want to investigate other possibilities. A good starting point is the Gray-Slater site listed above.

MacTEX for Experts

MacTEX installs TEX Live 2009 in /usr/local/texlive/2009. The distribution it installs is exactly the same as the distribution that would be obtained by using TEX Lives standard install script. TEX Live runs on almost all architectures: OS X, Windows, GNU/Linux,

and other Unix systems. The distribution is the same on all of these platforms; nothing has been added or removed to customize it for OS X. The MacTEX installer performs extra tasks which arent done when you install with TEX Lives standard script. MacTEX extends PATH and MANPATH so TEX binaries and man pages for the distribution are available within Unix shells. It installs a TEX Distribution preference pane for Apples System Preferences to manage TEX distributions on your machine. If you were using TEX Live 2008 or the TEX distribution in Fink or MacPorts, that distribution remains unchanged on your machine after installing MacTEX-2009. You can switch back and forth between TEX Live 2009 and your old distribution by pushing a radio button in the preference pane. When you push that button, PATH and MANPATH and all front ends and utilities are automatically recongured. A consequence of the mechanism used to make the panel work is that almost all TEX front ends and utilities on the Mac are automatically congured for TEX; this applies to most current programs available over the web, not just those we supply with MacTEX. On other Unix machines it is common to set environment variables like TEXINPUTS. While TEX Live recognizes these variables, it is usually not necessary or desirable to set them. MacTEX tries to guess your paper size at installation time. If it makes a mistake, you can set the paper size by running the program TeX Live Utility in /Applications/TeX, and selecting the Change Paper Size... item in the Action menu. Use TeX Live Utility to keep your distribution up to date. When the program starts, it lists packages in TeX for which updates are available. Push the Update All button to update these packages over the net. For details about these features, read What Is Installed in /Applications/TeX.

TEX Live Documentation

TEX Live comes with extensive documentation. To browse through the full set, click the link file:///usr/local/texlive/2009/index.html. This leads to several deceptively simple README links in various languages. If you follows links within these README les, you will soon reach extensive amounts of information, including some book length introductions to TEX. An important link is file:///usr/local/texlive/2009/doc.html which has links pointing to all of the html and pdf package documentation, sorted by package name. There are so many links that it is difcult to pick favorites; here are a few samples to show the 7

variety of available information: aE a A 139 page book on LTEX, The Not So Short Introduction to L T X2e, by Tobias Oetiker, Hubert Partl, Irene Hyna and Elisabeth Schlegl: file:///usr/local/texlive/2009/
texmf-dist/doc/latex/lshort-english/lshort.pdf

aE A Survey of Free Math Fonts for T X and L T X by Stephen G. Hartke: E The T X Live Guide for 2009, edited by Karl Berry: E

file:///usr/

local/texlive/2009/texmf-dist/doc/fonts/free-math-font-survey/survey.pdf file:///usr/local/texlive/

2009/texmf/doc/texlive/texlive-en/texlive-en.pdf

a The documentation for Beamer, a LTEX class to create presentations for a projector:
file:///usr/local/texlive/2009/texmf-dist/doc/latex/beamer/doc/beameruserguide. pdf

Spell Checking

Apples spell checker doesnt understand TEX, so it marks most TEX control words as misspelled. There are two solutions to this problem. The rst is to spell check documents after they are written, using the stand alone Excalibur in /Applications/TeX. The second is to download Anton Leuskis cocoAspell, a plugin for Apples system which does recognize TEX control words. To download and install the free cocoAspell, go to http:
//people.ict.usc.edu/~leuski/cocoaspell/

We do not include cocoAspell because you would need to go to this web page anyway to select a language and dictionary; at least 74 languages are supported.

Conguring on 10.3

If you are running on 10.3, three programs in this folder may need to be congured to nd the distribution of TEX installed by MacTEX. This reconguration need only done once, and then they will work with all modern TEX distributions on Mac OS X. TeXShop: Run the program, open Preferences, choose the Engine tab, and change the rst path setting to
/usr/texbin

LaTeXiT: Run the program, cancel the error dialog, open Preferences, select the Composition module, and change the rst three items to
/usr/texbin/pdflatex /usr/texbin/xelatex /usr/texbin/latex

To make these changes, successively select the radio buttons labeled pdatex, xelatex, and latex+dvipdf, type the new entry, and push return BibDesk: Run the program, open Preferences, select the Preview module, and change the entries in TeX Programs Locations to
/usr/texbin/pdflatex /usr/texbin/bibtex

You might also like