Environment and variables |
The evaluation and typesetting processes are controlled by variables. The environment is the collection all variables and values at a given point in the document, we also sometime call it the context.
Production of boxes is controlled by a number of typesetter variables. For example the text color is set by the color variable:
Some colored text.
|
|
Variables are also used for computational purposes during the evaluation step.
Weirdly
numbered list
|
|
The typesetting language uses dynamic scoping of
variables. That means that macros
In additions to variables set by primitives and markup inside a document, some variables are defined in the initial environment. This is the environment at the point (0 0) of the document, the start of the first paragraph.
Some variables, like header and footer variables, must be set inside the document, their initial environment value is ignored. Generally, they should be set by header and sectioning markup.