Thursday, December 13, 2007

Learn LaTeX : damn basic 1

Source: http://www.ecn.wfu.edu/%7ecottrell/wp.html
Link: LaTeX with Mac
very useful link

Text editors -- about Text editors and ASCII Character

Typesetter -- about TeX and LaTeX in general
-- introduce "document class" = type of document and "packages"= style of document
-- "preamble" of ASCII source file
--
"hands off" approach: just specify a document class and leave the rest up to the default macros
How this all work...


Text editors

What is a text editor and how does it differ from a word processor.
Text editor nowadays looks a bit like a word processor, except it has no typesetting functionality. (no pretense at representing the final printed appearance of the document.)

When you save your document, it is saved in the form of 'plain text', which in the US context usually means in "ASCII" (The American Standard Code for Information Interchange).

ASCII is composed of 128 characters (7-bit character set), including 0-9, the roman alphabet in both upper and lower case, the standard punctuation marks, and a number of special characters. An ASCII message will be understandable by any computer in the world.

Since a text editor does not insert any binary formatting codes, if you want to represent features such as italics you have to do this via 'mark-up'. That is you type in 'an annotation' (using nothing but ASCII), which will tell the typesetter to put the specified text into italics.

\textit {stuff you want in italics}

Actually, if you are using a text editor which is designed to cooperate with LaTex you would not have to type this yourself. You'd type some kind of shortcut sequence, select from a menu or click an icon, and the appropriate annotation would be inserted for you.


typesetter

The basic typesetting program that I have in mind is called TeX. It is available for free in formats suitable for just about every computer platform. TeX was written by Donald Knuth of Stanford University. He started work on TeX in 1977 and in 1990 he announced that he no longer intended to develop the program because by this time the program was essentially perfected.

If TeX is the basic typesetting engine, LaTeX is a large set of macros, initially developed by Leslie Lamport in the 1980s and now maintained by an international group of experts. These macros make life a lot easier for the average user of the system. LaTeX is still under active development, as new capabilities and packages are built on top of the underlying typesetter. Various "add-ons" for TeX are also on progress, such as a system which allows you to make PDF files directly from your ASCII source files.

"you indicate the desired structure and formatting of your document to LaTeX in the form of a set of annotations."

one very attractive feature of LaTeX is the ability to change the typeset apprearance of your text drastically and consistently with just a few commands. The overall appearance is controled by

1. "document class" that you choose (e.g. report, letter, article, book)
2. "packages" or style files that you decide to load.

By altering just one or two parameters in the "preamble" of your ASCII source file, you can completely change the font family, sizes of the fonts used, for examples.

You can get as complex as you care too, type setting with LaTeX. You can choose a "hands off" approach: just specify a document class and leave the rest up to the default macros.

The typesetting being of much higher quality than any word processor. (Natually, things like numbering of chapters, sections and footnotes, cross-references and so on, are all taken care of automatically.)

Or you can take a more "interventionist" approach, loading various packages (or even writing your own) to control various aspects of the typography. If this is your inclination, you can produce truly beautiful and individual output.


How this all work...

If you have a good TeX setup it's like this:
- you type your text into a TeX-aware editor
- when you reach a point where you'd like to take a look at the typeset version you make a menu choice or click a button in the editor to invoke the typesetter.
- open a previewer in which you see the text as it will appear at the printer.
- at some later point in the process you want to preview the updated file. Click the typesetter button again. This time you on't have to invoke the previewer again: if you've left it running in the background it will now automatically display the updated typeset version.
- when you're done with an editing session you can delete the typeset version of the file to conserve disk space. You just need to save the ASCII source file: the typeset version can easily be recreated whenever you need it.

Comment :
I think this is enough for the starter to know roughly and won't be loss with some annotation regard TeX, LaTeX, Preamble...

I'm currently enjoying and reading more...

No comments: