TeX
From Wikibooks, the open-content textbooks collection
Contents |
[edit] Introduction
TeX is a language used to typeset documents, especially ones containing mathematics. It has both programming and mark-up features. In this book we will describe "primitive TeX"—the basic engine for the macro languages plain TeX, LaTeX, ConTeXt, and so on. If you are new to TeX, then this is probably not what you want to read: you may be looking for LaTeX, a macro package for TeX that makes it easier to produce standard documents.
TeX is Donald Knuth's macro language, written to typeset documents. TeX can in principle be used for any kind of program (it is a Turing complete programming language), although it's not particularly pleasant to program in.
[edit] Other sources
The canonical source for learning the TeX language, both to write documents and to program, is the TeXbook by Donald Knuth. There's also a comprehensive programmer's reference called TeX by topic which the author has generously made available free at his website.
[edit] The Structure of TeX
We describe the basic anatomy of TeX: the registers, the parameters, and other resource that affect the processing of a TeX source file.
[edit] Basic Definitions
- Badness
- A measure of the quality of the spacing for a typeset line of text.
- baseline
- hbox
- overfull error
- underfull error
[edit] TeX Primitives
Here we describe each of the 300 or so TeX primitives.
- \valign
- \vbadness
- \vbox
- \vcenter
- \vfil
- \vfill
- \vfilneg
- \vfuzz
- \voffset
- \vrule
- \vsize
- \vskip
- \vsplit
- \vss
- \vtop
- \wd
- \widowpenalty
- \write
- \xdef
- \xleaders
- \xspaceskip
- \year
[edit] Sources on the Web
- www.tug.org — TeX Users Group
- ctan.tug.org/tex-archive/info/gentle/gentle.pdf — Michael Doob's guide to TeX

