76
1.4 The L
A
T
E
XInput File ♦
3
Some commands take an “argument,” placed within curly braces { } after the command
name. For example, \textbf{this text is bold} prints the text inside the braces in
boldface type: this text is bold
L
A
T
E
Xuses grouping to limit the effect of certain commands. Braces { ... } are used to
begin and end groups. (An environment is also a group; see page5.) For example, the
\large command is usually used inside a group:
{\large this is bigger than normal}
produces:
this is bigger than normal
Acommand such as \large is called a “declaration” because, unless it is given within
a group, its effect will continue until another declaration (in this case \normalsize)
counteracts it. Note the difference between a declaration used inside a group and a
command like \textbf{...}, which will not work unless an argument is provided inside
apair of braces following the command name.
The symbol % can be used to put a comment in your input file. When L
A
T
E
Xsees a %, it
ignores the rest of the line.
When you use commands that specify a length, such as a command to set the size of a
margin or a command to leave a certain amount of space, you will need to specify the
units of measurement. L
A
T
E
Xrecognizes the following units:
cm
centimeter
pt
printer’s point, ≈ 72 per inch
mm
millimeter
em
font-dependent width of “m”
in
inch
ex
font-dependent height of “x”
1.4.2 Entering Text
In the input file, words are separated by leaving one or more blank spaces. Paragraphs
are separated by leaving one or more blank lines. (You can also use the command \par
to indicate a new paragraph.) L
A
T
E
Xignores multiple blank spaces and multiple blank
lines in input files.
Type single quotation marks by using the left (‘) and right (’) single quote marks on
your keyboard. Type left double quotation marks by using using two single left quotes
(‘‘), and type right double quotation marks by using either two single right quotes (’’)
or the double quote key (").
There are three kinds of dashes in typeset documents: the hyphen (for compound words),
the endash (for such things as page number ranges), and the emdash (used as a punc-
tuation mark in English prose). Since there is only one dash on the keyboard, type -,
--, and --- to get -, –, and — .
To prevent two words from being split at a line break, tie them together with the tilde
character: for example Mr.~Smith will never appear with “Mr.” at the end of one line
and “Smith” at the start of the next.
Note that some characters have special meaning to L
A
T
E
X and must be entered in a
special way, as described in the next section.
Academic and Research Computing, RPI