[latexrefman-commits] [SCM] latexrefman updated: r624 - trunk
jimhefferon at gnu.org.ua
jimhefferon at gnu.org.ua
Sat May 19 21:34:10 CEST 2018
Author: jimhefferon
Date: 2018-05-19 22:34:10 +0300 (Sat, 19 May 2018)
New Revision: 624
Modified:
trunk/ChangeLog
trunk/latex2e.html
trunk/latex2e.info
trunk/latex2e.pdf
trunk/latex2e.texi
Log:
Through latex-info's Cross References, Commands, Page Layout
Modified: trunk/ChangeLog
===================================================================
--- trunk/ChangeLog 2018-05-19 14:07:46 UTC (rev 623)
+++ trunk/ChangeLog 2018-05-19 19:34:10 UTC (rev 624)
@@ -1,3 +1,9 @@
+2018-05-19 Jim Hefferon <jhefferon at smcvt.edu>
+
+ * latex2e.texi Continue going through latex-info. Through that
+ doc's Cross References, Commands, Page Layout. Adjust wording
+ as it arises, including adding error messages.
+
2018-05-18 Karl Berry <karl at freefriends.org>
* text: "GNU/Linux", @TeX{} Live, MiK at TeX{}, just @samp.
Modified: trunk/latex2e.html
===================================================================
--- trunk/latex2e.html 2018-05-19 14:07:46 UTC (rev 623)
+++ trunk/latex2e.html 2018-05-19 19:34:10 UTC (rev 624)
@@ -2541,6 +2541,12 @@
<a name="index-_005conecolumn"></a>
<a name="index-one_002dcolumn-output"></a>
+<p>Synopsis:
+</p>
+<div class="example">
+<pre class="example">\onecolumn
+</pre></div>
+
<p>Start a new page and produce single-column output. If the document is
given the class option <code>onecolumn</code> then this is the default
behavior (see <a href="#Document-class-options">Document class options</a>).
@@ -3534,39 +3540,52 @@
<a name="index-cross-references"></a>
-<p>One reason for numbering things such as figures and equations is to
-refer the reader to them, as in “See Figure~3 for more details.”
-</p>
<a name="index-label"></a>
-<p>Including the figure number in the source is poor practice since if that
-number changes as the document evolves then you must remember to update
-this reference by hand. Instead, LaTeX has you write a <em>label</em>
-like <code>\label{eq:GreensThm}</code> and refer to it with <code>See
-equation~\ref{eq:GreensThm}</code>.
+<p>We often want something like ‘<samp>See Theorem~31</samp>’. But by-hand typing
+the 31 is poor practice. Instead you should write a <em>label</em> such as
+<code>\label{eq:GreensThm}</code> and then <em>reference</em> it, as with
+<code>See equation~\ref{eq:GreensThm}</code>. LaTeX will automatically
+work out the number, put it into the output, and will change that number
+later if needed.
</p>
-<p>LaTeX writes the information from the labels to a file with the same
-name as the file containing the <code>\label{...}</code> but with an
-<samp>.aux</samp> extension. (The information has the format
-<code>\newlabel{<var>label</var>}{{<var>currentlabel</var>}{<var>pagenumber</var>}}</code>
-where <var>currentlabel</var> is the current value of the macro
-<code>\@currentlabel</code> that is usually updated whenever you call
-<code>\refstepcounter{<var>counter</var>}</code>.)
+<div class="example">
+<pre class="example">We will later see this with Theorem~\ref{th:GreensThm}. % This is a forward reference
+...
+\begin{theorem} \label{th:GreensThm}
+ ...
+\end{theorem}
+...
+See Theorem~\ref{th:GreensThm} on page~\pageref{th:GreensThm}.
+</pre></div>
+
+<p>LaTeX tracks cross reference information in a file having the
+extension <samp>.aux</samp> and with the same base name as the file containing
+the <code>\label</code>. So if <code>\label</code> is in <samp>calculus.tex</samp> then
+the information is in <samp>calculus.aux</samp>. LaTeX puts the
+information in that file every time it across a <code>\label</code>.
</p>
<a name="index-forward-reference"></a>
<a name="index-reference_002c-forward"></a>
-<p>The most common side effect of the prior paragraph happens when your
-document has a <em>forward reference</em>, a <code>\ref{<var>key</var>}</code> that
-appears earlier than the associated <code>\label{<var>key</var>}</code>; see the
-example in the <code>\pageref{...}</code> description. LaTeX gets the
-information for references from the <samp>.aux</samp> file. If this is the
-first time you are compiling the document then you will get a message
-<code>LaTeX Warning: Label(s) may have changed. Rerun to get
-cross references right.</code> and in the output the reference will appear as
-two question marks ‘<samp>??</samp>’, in boldface. Or, if you change some
-things so the references change then you get the same warning and the
-output contains the old reference information. The solution in either
-case is just to compile the document a second time.
+<p>The behavior described in the prior paragraph results in a quirk that
+happens when your document has a <em>forward reference</em>, a <code>\ref</code>
+that appears before the associated <code>\label</code>. If this is the first
+time that you are compiling the document then you will get ‘<samp>LaTeX
+Warning: Label(s) may have changed. Rerun to get cross references right</samp>’
+and in the output the forward reference will appear as two question
+marks ‘<samp>??</samp>’, in boldface. A similar thing happens if you
+change some things so the references changes; you get the same warning
+and the output contains the old reference information. In both cases,
+to resolve this just compile the document a second time.
</p>
+<a name="index-package_002c-cleveref"></a>
+<a name="index-cleveref-package"></a>
+
+<p>The <code>cleveref</code> package enhances LaTeX’s cross referencing
+features. You can have the format of the cross-references determined
+automatically according to the type of cross-reference, such as
+equation, section, etc., and the context in which you use that
+reference.
+</p>
<table class="menu" border="0" cellspacing="0">
<tr><td align="left" valign="top">• <a href="#g_t_005clabel" accesskey="1">\label</a>:</td><td> </td><td align="left" valign="top">Assign a symbolic name to a piece of text.
</td></tr>
@@ -3632,11 +3651,17 @@
<p>Thus, <code>\label{fig:Euler}</code> is a label for a figure with a portrait
of the great man.
</p>
-<p>In this example below the key <code>sec:test</code> will get the number of the
-current section and the key <code>fig:test</code> will get the number of the
-figure. (Incidentally, put labels after captions in figures and
-tables.)
+<p>Inside the auxillary file the reference information is kept in the
+format
+<code>\newlabel{<var>label</var>}{{<var>currentlabel</var>}{<var>pagenumber</var>}}</code>.
+Here <var>currentlabel</var> is the current value of the macro
+<code>\@currentlabel</code> that is usually updated whenever you call
+<code>\refstepcounter{<var>counter</var>}</code>.
</p>
+<p>Below, the key <code>sec:test</code> will get the number of the current
+section and the key <code>fig:test</code> will get the number of the figure.
+(Incidentally, put labels after captions in figures and tables.)
+</p>
<div class="example">
<pre class="example">\section{section name}
\label{sec:test}
@@ -3672,11 +3697,15 @@
<p>Produce the page number of the place in the text where the corresponding
<code>\label</code>{<var>key</var>} command appears.
</p>
-<p>In this example the <code>\label{eq:main}</code> is used both for the
-formula number and for the page number. (Note that the two references
-are forward references, so this document would need to be compiled twice
-to resolve those.)
+<p>If there is no <code>\label{<var>key</var>}</code> then you get something like
+‘<samp>LaTeX Warning: Reference `th:GrensThm' on page 1 undefined on
+input line 11.</samp>’
</p>
+<p>Below, the <code>\label{eq:main}</code> is used both for the formula number
+and for the page number. (Note that the two references are forward
+references so this document would need to be compiled twice to resolve
+those.)
+</p>
<div class="example">
<pre class="example">The main result is formula~\ref{eq:main} on page~\pageref{eq:main}.
...
@@ -3713,10 +3742,14 @@
<code>\label</code> command (see <a href="#g_t_005clabel">\label</a>). It does not produce any text,
such as the word ‘Section’ or ‘Figure’, just the bare number itself.
</p>
-<p>In this example, the <code>\ref{popular}</code> produces ‘<samp>2</samp>’. Note
-that it is a forward reference since it comes before
-<code>\label{popular}</code>.
+<p>If there is no <code>\label{<var>key</var>}</code> then you get something like
+‘<samp>LaTeX Warning: Reference `th:GrensThm' on page 1 undefined on
+input line 11.</samp>’
</p>
+<p>In this example the <code>\ref{popular}</code> produces ‘<samp>2</samp>’. Note that
+it is a forward reference since it comes before <code>\label{popular}</code>
+so this document would have to be compiled twice.
+</p>
<div class="example">
<pre class="example">The most widely-used format is item number~\ref{popular}.
\begin{enumerate}
@@ -8007,7 +8040,6 @@
<p>LaTeX has support for making new commands of many different kinds.
</p>
-
<table class="menu" border="0" cellspacing="0">
<tr><td align="left" valign="top">• <a href="#g_t_005cnewcommand-_0026-_005crenewcommand" accesskey="1">\newcommand & \renewcommand</a>:</td><td> </td><td align="left" valign="top">(Re)define a new command.
</td></tr>
@@ -8047,8 +8079,7 @@
<a name="index-defining-a-new-command"></a>
<a name="index-new-commands_002c-defining"></a>
-<p><code>\newcommand</code> and <code>\renewcommand</code> define and redefine a
-command, respectively. Synopses:
+<p>Synopses:
</p>
<div class="example">
<pre class="example"> \newcommand{\<var>cmd</var>}[<var>nargs</var>][<var>optargdefault</var>]{<var>defn</var>}
@@ -8057,6 +8088,9 @@
\renewcommand*{\<var>cmd</var>}[<var>nargs</var>][<var>optargdefault</var>]{<var>defn</var>}
</pre></div>
+<p>Define or redefine a command. See also the discussion of
+<code>\DeclareRobustCommand</code> in <a href="#Class-and-package-commands">Class and package commands</a>.
+</p>
<a name="index-starred-form_002c-defining-new-commands"></a>
<a name="index-_002a_002dform_002c-defining-new-commands"></a>
<p>The starred form of these two commands requires that the arguments not
@@ -8065,9 +8099,11 @@
</p>
<dl compact="compact">
<dt><var>cmd</var></dt>
-<dd><p>Required; <code>\<var>cmd</var></code> is the command name. For <code>\newcommand</code>, it
-must not be already defined and must not begin with <code>\end</code>. For
-<code>\renewcommand</code>, it must already be defined.
+<dd>
+<p>Required; the command name. It must begin with a backslash, <code>\</code>,
+and must not begin with <code>\end</code>. For <code>\newcommand</code>, it must
+not be already defined. For <code>\renewcommand</code>, this name must
+already be defined.
</p>
</dd>
<dt><var>nargs</var></dt>
@@ -8119,6 +8155,12 @@
<p>Redefining an existing command is similar:
<code>\renewcommand{\qedsymbol}{{\small QED}}</code>.
</p>
+<p>If you try to define a command and the name has already been used then
+you get something like ‘<samp>LaTeX Error: Command \fred already
+defined. Or name \end... illegal, see p.192 of the manual</samp>’. If you try
+to redefine a command and the name has not yet been used then you get
+something like ‘<samp>LaTeX Error: \hank undefined</samp>’.
+</p>
<p>Here’s a command definition with one required argument:
</p>
<div class="example">
@@ -8250,7 +8292,7 @@
</pre></div>
<p>This command takes one required argument, which must begin with a
-backslash (‘<samp>\</samp>’). It creates a new length register named
+backslash, <code>\</code>. It creates a new length register named
<code>\<var>arg</var></code>, which is a place to hold (rubber) lengths such as
<code>1in plus.2in minus.1in</code> (what plain TeX calls a <code>skip</code>
register). The register gets an initial value of zero. The control
@@ -8277,11 +8319,10 @@
<pre class="example">\newsavebox{\<var>cmd</var>}
</pre></div>
-<p>Defines <code>\<var>cmd</var></code> to refer to a new bin for storing boxes.
-Such a box is for holding typeset material, to use multiple times
-(see <a href="#Boxes">Boxes</a>) or to measure or manipulate. The name
-<code>\<var>cmd</var></code> must start with a backslash (‘<samp>\</samp>’), and must not
-be already defined.
+<p>Defines <code>\<var>cmd</var></code> to refer to a new bin for storing boxes. Such
+a box is for holding typeset material, to use multiple times
+(see <a href="#Boxes">Boxes</a>) or to measure or manipulate. The name <code>\<var>cmd</var></code>
+must start with a backslash, <code>\</code>, and must not be already defined.
</p>
<p>The allocation of a box is global. This command is fragile
(see <a href="#g_t_005cprotect">\protect</a>).
@@ -8302,16 +8343,18 @@
<a name="index-defining-new-environments"></a>
<a name="index-redefining-environments"></a>
-<p>These commands define or redefine an environment <var>env</var>, that is,
-<code>\begin{<var>env</var>} <var>body</var> \end{<var>env</var>}</code>. Synopses:
+<p>Synopses:
</p>
<div class="example">
-<pre class="example"> \newenvironment{<var>env</var>}[<var>nargs</var>][<var>optargdefault</var>]{<var>begdefn</var>}{<var>enddefn</var>}
- \newenvironment*{<var>env</var>}[<var>nargs</var>][<var>optargdefault</var>]{<var>begdefn</var>}{<var>enddefn</var>}
- \renewenvironment{<var>env</var>}[<var>nargs</var>][<var>optargdefault</var>]{<var>begdefn</var>}{<var>enddefn</var>}
-\renewenvironment*{<var>env</var>}[<var>nargs</var>][<var>optargdefault</var>]{<var>begdefn</var>}{<var>enddefn</var>}
+<pre class="example"> \newenvironment{<var>env</var>}[<var>nargs</var>][<var>optargdefault</var>]{<var>begdef</var>}{<var>enddef</var>}
+ \newenvironment*{<var>env</var>}[<var>nargs</var>][<var>optargdefault</var>]{<var>begdef</var>}{<var>enddef</var>}
+ \renewenvironment{<var>env</var>}[<var>nargs</var>][<var>optargdefault</var>]{<var>begdef</var>}{<var>enddef</var>}
+\renewenvironment*{<var>env</var>}[<var>nargs</var>][<var>optargdefault</var>]{<var>begdef</var>}{<var>enddef</var>}
</pre></div>
+<p>Define or redefine the environment <var>env</var>, that is, create the
+construct <code>\begin{<var>env</var>} <var>body</var> \end{<var>env</var>}</code>.
+</p>
<a name="index-_002a_002dform-of-environment-commands"></a>
<p>The starred form of these commands requires that the arguments not
contain multiple paragraphs of text. The body of these environments can
@@ -8320,8 +8363,8 @@
<dl compact="compact">
<dt><var>env</var></dt>
<dd><p>Required; the environment name. It consists only of letters or the
-<code>*</code> character, and thus does not begin with backslash
-(<code>\</code>). It must not begin with the string <code>end</code>. For
+<code>*</code> character, and thus does not begin with backslash, <code>\</code>.
+It must not begin with the string <code>end</code>. For
<code>\newenvironment</code>, the name <var>env</var> must not be the name of an
already existing environment, and also the command <code>\<var>env</var></code>
must be undefined. For <code>\renewenvironment</code>, <var>env</var> must be the
@@ -8332,7 +8375,7 @@
<dd><p>Optional; an integer from 0 to 9 denoting the number of arguments of
that the environment will take. When the environment is used these
arguments appear after the <code>\begin</code>, as in
-<code>\begin{<var>env</var>}{<var>arg1</var>}…{<var>argn</var>}</code>. If this
+<code>\begin{<var>env</var>}{<var>arg1</var>} .... {<var>argn</var>}</code>. If this
argument is not present then the default is for the environment to have
no arguments. When redefining an environment, the new version can have
a different number of arguments than the old version.
@@ -8360,27 +8403,33 @@
<code>#1</code> expanding to the empty string.
</p>
</dd>
-<dt><var>begdefn</var></dt>
+<dt><var>begdef</var></dt>
<dd><p>Required; the text expanded at every occurrence of
<code>\begin{<var>env</var>}</code>. Within <var>begdef</var>, the <var>n</var>th
-positional parameter (i.e., <code>#<var>n</var></code>) is replaced by the text
-of the <var>n</var>th argument.
+positional parameter (i.e., <code>#1</code>, <code>#2</code>, etc.) is replaced by
+the text of the <var>n</var>th argument.
</p>
</dd>
-<dt><var>enddefn</var></dt>
+<dt><var>enddef</var></dt>
<dd><p>Required; the text expanded at every occurrence of
<code>\end{<var>env</var>}</code>. This may not contain any positional
-parameters, so <code>#<var>n</var></code> cannot be used here (but see the final
-example below).
+parameters, so you cannot use <code>#1</code>, <code>#2</code>, etc., here (but see
+the final example below).
</p>
</dd>
</dl>
-<p>All environments, that is to say the <var>begdefn</var> code, the environment
-body and the <var>enddefn</var> code, are processed within a group. Thus, in
+<p>All environments, that is to say the <var>begdef</var> code, the environment
+body, and the <var>enddef</var> code, are processed within a group. Thus, in
the first example below, the effect of the <code>\small</code> is limited to
the quote and does not extend to material following the environment.
</p>
+<p>If you try to define an environment and the name has already been used
+then you get something like ‘<samp>LaTeX Error: Command \fred already
+defined. Or name \end... illegal, see p.192 of the manual</samp>’. If you try
+to redefine an environment and the name has not yet been used then you
+get something like ‘<samp>LaTeX Error: Environment hank undefined.</samp>’.
+</p>
<p>This example gives an environment like LaTeX’s <code>quotation</code>
except that it will be set in smaller type:
</p>
@@ -8414,7 +8463,7 @@
</pre></div>
<p>The final example shows how to save the value of an argument to use in
-<var>enddefn</var>, in this case in a box (see <a href="#g_t_005csbox">\sbox</a>):
+<var>enddef</var>, in this case in a box (see <a href="#g_t_005csbox">\sbox</a>):
</p>
<div class="example">
<pre class="example">\newsavebox{\quoteauthor}
@@ -8443,7 +8492,7 @@
<a name="index-theorem_002dlike-environment"></a>
<a name="index-environment_002c-theorem_002dlike"></a>
-<p>Define a new theorem-like environment. Synopses:
+<p>Synopses:
</p>
<div class="example">
<pre class="example">\newtheorem{<var>name</var>}{<var>title</var>}
@@ -8451,21 +8500,20 @@
\newtheorem{<var>name</var>}[<var>numbered_like</var>]{<var>title</var>}
</pre></div>
-<p>Using the first form, <code>\newtheorem{<var>name</var>}{<var>title</var>}</code>
-creates an environment that will be labelled with <var>title</var>. See the
-first example below.
+<p>Define a new theorem-like environment. The first form,
+<code>\newtheorem{<var>name</var>}{<var>title</var>}</code>, creates an environment
+that will be labelled with <var>title</var>; see the first example below.
</p>
-<p>The second form
-<code>\newtheorem{<var>name</var>}{<var>title</var>}[<var>numbered_within</var>]</code>
+<p>The second form,
+<code>\newtheorem{<var>name</var>}{<var>title</var>}[<var>numbered_within</var>]</code>,
creates an environment whose counter is subordinate to the existing
-counter <var>numbered_within</var> (its counter will be reset when
-<var>numbered_within</var> is reset).
+counter <var>numbered_within</var>, so this counter will be reset when
+<var>numbered_within</var> is reset.
</p>
-
<p>The third form
<code>\newtheorem{<var>name</var>}[<var>numbered_like</var>]{<var>title</var>}</code>,
-with optional argument between the two required arguments, will create
-an environment whose counter will share the previously defined counter
+with optional argument between the two required arguments, creates an
+environment whose counter will share the previously defined counter
<var>numbered_like</var>.
</p>
<p>You can specify one of <var>numbered_within</var> and <var>numbered_like</var>,
@@ -8482,13 +8530,13 @@
</p>
<dl compact="compact">
<dt><var>name</var></dt>
-<dd><p>The name of the environment. It must not begin with a backslash
-(‘<samp>\</samp>’). It must not be the name of an existing environment; indeed,
-the command name <code>\<var>name</var></code> must not already be defined as anything.
+<dd><p>The name of the environment. It must not begin with a backslash,
+<code>\</code>. It must not be the name of an existing environment, and
+the command name <code>\<var>name</var></code> must not already be defined.
</p>
</dd>
<dt><var>title</var></dt>
-<dd><p>The text printed at the beginning of the environment, before the
+<dd><p>The text to be printed at the beginning of the environment, before the
number. For example, ‘<samp>Theorem</samp>’.
</p>
</dd>
@@ -8585,38 +8633,33 @@
<a name="index-fonts_002c-new-commands-for"></a>
<a name="index-defining-new-fonts"></a>
-<p><code>\newfont</code>, now obsolete, defines a command that will switch fonts.
-Synopsis:
+<p>This command is obsolete. This description is here only to help with old
+documents. New document should define fonts in families through the New
+Font Selection Scheme which allows you to, for example, associate a
+boldface with a roman (see <a href="#Fonts">Fonts</a>).
</p>
+<p>Synopsis:
+</p>
<div class="example">
<pre class="example">\newfont{\<var>cmd</var>}{<var>font description</var>}
</pre></div>
-<p>This defines a control sequence <code>\<var>cmd</var></code> that will change the
-current font. LaTeX will look on your system for a file named
-<samp><var>fontname</var>.tfm</samp>. The control sequence must must not already
-be defined. It must begin with a backslash (‘<samp>\</samp>’).
+<p>Define a command <code>\<var>cmd</var></code> that will change the current font.
+The control sequence must must not already be defined. It must begin
+with a backslash, <code>\</code>.
</p>
-<a name="index-_002efd-file"></a>
-<p>This command is obsolete. It is a low-level command for setting up an
-individual font. Today fonts are almost always defined in families
-(which allows you to, for example, associate a boldface with a roman)
-through the so-called “New Font Selection Scheme”, either by using
-<samp>.fd</samp> files or through the use of an engine that can access
-system fonts such as XeLaTeX (see <a href="#TeX-engines">TeX engines</a>).
-</p>
<a name="index-at-clause_002c-in-font-definitions"></a>
<a name="index-design-size_002c-in-font-definitions"></a>
-<p>But since it is part of LaTeX, here is an explanation: the
-<var>font description</var> consists of a <var>fontname</var> and an optional
-<em>at clause</em>; this can have the form either <code>at <var>dimen</var></code>
-or <code>scaled <var>factor</var></code>, where a <var>factor</var> of ‘<samp>1000</samp>’
-means no scaling. For LaTeX’s purposes, all this does is scale all
-the character and other font dimensions relative to the font’s design
-size, which is a value defined in the <samp>.tfm</samp> file.
+<p>The <var>font description</var> consists of a <var>fontname</var> and an optional
+<em>at clause</em>. LaTeX will look on your system for a file named
+<samp><var>fontname</var>.tfm</samp>. The at clause can have the form either
+<code>at <var>dimen</var></code> or <code>scaled <var>factor</var></code>, where a
+<var>factor</var> of ‘<samp>1000</samp>’ means no scaling. For LaTeX’s purposes,
+all this does is scale all the character and other font dimensions
+relative to the font’s design size, which is a value defined in the
+<samp>.tfm</samp> file.
</p>
-<p>This example defines two equivalent fonts and typesets a few
-characters in each:
+<p>This defines two equivalent fonts and typesets a few characters in each.
</p>
<div class="example">
<pre class="example">\newfont{\testfontat}{cmb10 at 11pt}
@@ -8968,7 +9011,7 @@
<code>ref</code> value (see <a href="#g_t_005cref">\ref</a>). This command is fragile
(see <a href="#g_t_005cprotect">\protect</a>).
</p>
-<p>Put in the docuemnt preamble, this example makes a new list environment
+<p>Put in the document preamble, this example makes a new list environment
enumerated with <var>testcounter</var>:
</p>
<div class="example">
@@ -13633,7 +13676,7 @@
the graphic.
</p>
<p>The behavior of file system search code is necessarily platform
-dependent. In this document we cover Linux, Macintosh, and Windows, as
+dependent. In this document we cover GNU/Linux, Macintosh, and Windows, as
those systems are typically configured. For other situations consult
the documentation in <samp>grfguide.pdf</samp>, or the LaTeX source, or your
TeX distribution’s documentation.
@@ -13768,7 +13811,7 @@
not found</samp>’. Note that you must include the periods at the start of the
extensions.
</p>
-<p>Because Linux and Macintosh filenames are case sensitive, the list of
+<p>Because GNU/Linux and Macintosh filenames are case sensitive, the list of
file extensions is case sensitive on those platforms. The Windows
platform is not case sensitive.
</p>
@@ -15673,7 +15716,7 @@
</pre></div>
<p>Running LaTeX on <samp>constitution.tex</samp> makes the material from the
-three files appear in the document but also generates the auxillary
+three files appear in the document but also generates the auxiliary
files <samp>preamble.aux</samp>, <samp>articles.aux</samp>, and
<samp>amendments.tex</samp>. These contain information such as page numbers
and cross-references (see <a href="#Cross-references">Cross references</a>). If you now comment out
@@ -15705,9 +15748,9 @@
</pre></div>
<p>To make your document portable across distributions and platforms you
-should avoid spaces in the file names. The tradition is to instead use
-underscores. That said, for the name ‘<samp><samp>amo amas amat</samp></samp>’, this
-works under TeX Live on Linux
+should avoid spaces in the file names. The tradition is to instead use
+dashes or underscores. Nevertheless, for the name ‘<samp>amo amas amat</samp>’,
+this works under TeX Live on GNU/Linux:
</p>
<div class="example">
<pre class="example">\documentclass{book}
@@ -15719,7 +15762,7 @@
\end{document}
</pre></div>
-<p>and this works under MiKTeX on Windows.
+<p>and this works under MiKTeX on Windows:
</p>
<div class="example">
<pre class="example">\documentclass{book}
@@ -15770,13 +15813,13 @@
current file. For a more sophisticated inclusion mechanism see
<a href="#g_t_005cinclude-_0026-_005cincludeonly">\include & \includeonly</a>.
</p>
-<p>If <var>file</var> end with ‘<samp>.tex</samp>’ then LaTeX looks for the filename
-as it is. If <var>file</var> does not end in ‘<samp>.tex</samp>’ then LaTeX first
-tries the filename with that extension, so <code>\include{macros}</code>
-will cause LaTeX to first look for <samp>macros.tex</samp>; this is the
-usual case. If there is no such file then the system tries the original
-file name, here ‘<samp><samp>macros</samp></samp>’, without an extension. (This may
-vary by distribution.)
+<p>If <var>file</var> end with ‘<samp>.tex</samp>’ then LaTeX looks for the
+filename as it is. If <var>file</var> does not end in ‘<samp>.tex</samp>’ then
+LaTeX first tries the filename with that extension, so
+<code>\include{macros}</code> will cause LaTeX to first look for
+<samp>macros.tex</samp>; this is the usual case. If there is no such file
+then the system tries the original file name, here ‘<samp>macros</samp>’,
+without an extension. (This may vary by distribution.)
</p>
<hr>
@@ -16971,6 +17014,7 @@
<tr><td></td><td valign="top"><a href="#index-class-options-1">class options</a>:</td><td> </td><td valign="top"><a href="#Class-and-package-structure">Class and package structure</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-class-options-2">class options</a>:</td><td> </td><td valign="top"><a href="#Class-and-package-commands">Class and package commands</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-classes-of-documents">classes of documents</a>:</td><td> </td><td valign="top"><a href="#Document-classes">Document classes</a></td></tr>
+<tr><td></td><td valign="top"><a href="#index-cleveref-package"><code>cleveref</code> <span class="roman">package</span></a>:</td><td> </td><td valign="top"><a href="#Cross-references">Cross references</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-closing-letters">closing letters</a>:</td><td> </td><td valign="top"><a href="#g_t_005cclosing">\closing</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-closing-quote">closing quote</a>:</td><td> </td><td valign="top"><a href="#Text-symbols">Text symbols</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-code_002c-typesetting">code, typesetting</a>:</td><td> </td><td valign="top"><a href="#verbatim">verbatim</a></td></tr>
@@ -17366,6 +17410,7 @@
<tr><td></td><td valign="top"><a href="#index-package_002c-amsmath-1"><span class="roman">package</span>, <code>amsmath</code></a>:</td><td> </td><td valign="top"><a href="#displaymath">displaymath</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-package_002c-babel"><span class="roman">package</span>, <code>babel</code></a>:</td><td> </td><td valign="top"><a href="#thebibliography">thebibliography</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-package_002c-babel-1"><span class="roman">package</span>, <code>babel</code></a>:</td><td> </td><td valign="top"><a href="#Accents">Accents</a></td></tr>
+<tr><td></td><td valign="top"><a href="#index-package_002c-cleveref"><span class="roman">package</span>, <code>cleveref</code></a>:</td><td> </td><td valign="top"><a href="#Cross-references">Cross references</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-package_002c-datetime"><span class="roman">package</span>, <code>datetime</code></a>:</td><td> </td><td valign="top"><a href="#g_t_005ctoday">\today</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-package_002c-enumitem"><span class="roman">package</span>, <code>enumitem</code></a>:</td><td> </td><td valign="top"><a href="#list">list</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-package_002c-etoolbox"><span class="roman">package</span>, <code>etoolbox</code></a>:</td><td> </td><td valign="top"><a href="#Class-and-package-commands">Class and package commands</a></td></tr>
@@ -17769,7 +17814,6 @@
<tr><th><a name="Command-Index_fn_symbol-4">.</a></th><td></td><td></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002eaux-file"><code>.aux <span class="roman">file</span></code></a>:</td><td> </td><td valign="top"><a href="#Output-files">Output files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002edvi-file"><code>.dvi <span class="roman">file</span></code></a>:</td><td> </td><td valign="top"><a href="#Output-files">Output files</a></td></tr>
-<tr><td></td><td valign="top"><a href="#index-_002efd-file"><code>.fd <span class="roman">file</span></code></a>:</td><td> </td><td valign="top"><a href="#g_t_005cnewfont">\newfont</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002elof-file"><code>.lof <span class="roman">file</span></code></a>:</td><td> </td><td valign="top"><a href="#Output-files">Output files</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002elof-file-1"><code>.lof <span class="roman">file</span></code></a>:</td><td> </td><td valign="top"><a href="#Tables-of-contents">Tables of contents</a></td></tr>
<tr><td></td><td valign="top"><a href="#index-_002elog-file"><code>.log <span class="roman">file</span></code></a>:</td><td> </td><td valign="top"><a href="#Output-files">Output files</a></td></tr>
Modified: trunk/latex2e.info
===================================================================
--- trunk/latex2e.info 2018-05-19 14:07:46 UTC (rev 623)
+++ trunk/latex2e.info 2018-05-19 19:34:10 UTC (rev 624)
@@ -1432,8 +1432,12 @@
5.1 '\onecolumn'
================
-Start a new page and produce single-column output. If the document is
-given the class option 'onecolumn' then this is the default behavior
+Synopsis:
+
+ \onecolumn
+
+ Start a new page and produce single-column output. If the document
+is given the class option 'onecolumn' then this is the default behavior
(*note Document class options::).
This command is fragile (*note \protect::).
@@ -2136,34 +2140,43 @@
7 Cross references
******************
-One reason for numbering things such as figures and equations is to
-refer the reader to them, as in "See Figure~3 for more details."
+We often want something like 'See Theorem~31'. But by-hand typing the
+31 is poor practice. Instead you should write a "label" such as
+'\label{eq:GreensThm}' and then "reference" it, as with 'See
+equation~\ref{eq:GreensThm}'. LaTeX will automatically work out the
+number, put it into the output, and will change that number later if
+needed.
- Including the figure number in the source is poor practice since if
-that number changes as the document evolves then you must remember to
-update this reference by hand. Instead, LaTeX has you write a "label"
-like '\label{eq:GreensThm}' and refer to it with 'See
-equation~\ref{eq:GreensThm}'.
+ We will later see this with Theorem~\ref{th:GreensThm}. % This is a forward reference
+ ...
+ \begin{theorem} \label{th:GreensThm}
+ ...
+ \end{theorem}
+ ...
+ See Theorem~\ref{th:GreensThm} on page~\pageref{th:GreensThm}.
- LaTeX writes the information from the labels to a file with the same
-name as the file containing the '\label{...}' but with an '.aux'
-extension. (The information has the format
-'\newlabel{LABEL}{{CURRENTLABEL}{PAGENUMBER}}' where CURRENTLABEL is the
-current value of the macro '\@currentlabel' that is usually updated
-whenever you call '\refstepcounter{COUNTER}'.)
+ LaTeX tracks cross reference information in a file having the
+extension '.aux' and with the same base name as the file containing the
+'\label'. So if '\label' is in 'calculus.tex' then the information is
+in 'calculus.aux'. LaTeX puts the information in that file every time
+it across a '\label'.
- The most common side effect of the prior paragraph happens when your
-document has a "forward reference", a '\ref{KEY}' that appears earlier
-than the associated '\label{KEY}'; see the example in the
-'\pageref{...}' description. LaTeX gets the information for references
-from the '.aux' file. If this is the first time you are compiling the
-document then you will get a message 'LaTeX Warning: Label(s) may have
-changed. Rerun to get cross references right.' and in the output the
-reference will appear as two question marks '??', in boldface. Or, if
-you change some things so the references change then you get the same
-warning and the output contains the old reference information. The
-solution in either case is just to compile the document a second time.
+ The behavior described in the prior paragraph results in a quirk that
+happens when your document has a "forward reference", a '\ref' that
+appears before the associated '\label'. If this is the first time that
+you are compiling the document then you will get 'LaTeX Warning:
+Label(s) may have changed. Rerun to get cross references right' and in
+the output the forward reference will appear as two question marks '??',
+in boldface. A similar thing happens if you change some things so the
+references changes; you get the same warning and the output contains the
+old reference information. In both cases, to resolve this just compile
+the document a second time.
+ The 'cleveref' package enhances LaTeX's cross referencing features.
+You can have the format of the cross-references determined automatically
+according to the type of cross-reference, such as equation, section,
+etc., and the context in which you use that reference.
+
* Menu:
* \label:: Assign a symbolic name to a piece of text.
@@ -2209,11 +2222,15 @@
Thus, '\label{fig:Euler}' is a label for a figure with a portrait of
the great man.
- In this example below the key 'sec:test' will get the number of the
-current section and the key 'fig:test' will get the number of the
-figure. (Incidentally, put labels after captions in figures and
-tables.)
+ Inside the auxillary file the reference information is kept in the
+format '\newlabel{LABEL}{{CURRENTLABEL}{PAGENUMBER}}'. Here
+CURRENTLABEL is the current value of the macro '\@currentlabel' that is
+usually updated whenever you call '\refstepcounter{COUNTER}'.
+ Below, the key 'sec:test' will get the number of the current section
+and the key 'fig:test' will get the number of the figure.
+(Incidentally, put labels after captions in figures and tables.)
+
\section{section name}
\label{sec:test}
This is Section~\ref{sec:test}.
@@ -2237,11 +2254,14 @@
Produce the page number of the place in the text where the
corresponding '\label'{KEY} command appears.
- In this example the '\label{eq:main}' is used both for the formula
-number and for the page number. (Note that the two references are
-forward references, so this document would need to be compiled twice to
-resolve those.)
+ If there is no '\label{KEY}' then you get something like 'LaTeX
+Warning: Reference `th:GrensThm' on page 1 undefined on input line 11.'
+ Below, the '\label{eq:main}' is used both for the formula number and
+for the page number. (Note that the two references are forward
+references so this document would need to be compiled twice to resolve
+those.)
+
The main result is formula~\ref{eq:main} on page~\pageref{eq:main}.
...
\begin{equation} \label{eq:main}
@@ -2263,9 +2283,13 @@
does not produce any text, such as the word 'Section' or 'Figure', just
the bare number itself.
- In this example, the '\ref{popular}' produces '2'. Note that it is a
-forward reference since it comes before '\label{popular}'.
+ If there is no '\label{KEY}' then you get something like 'LaTeX
+Warning: Reference `th:GrensThm' on page 1 undefined on input line 11.'
+ In this example the '\ref{popular}' produces '2'. Note that it is a
+forward reference since it comes before '\label{popular}' so this
+document would have to be compiled twice.
+
The most widely-used format is item number~\ref{popular}.
\begin{enumerate}
\item Plain \TeX
@@ -5280,23 +5304,27 @@
12.1 '\newcommand' & '\renewcommand'
====================================
-'\newcommand' and '\renewcommand' define and redefine a command,
-respectively. Synopses:
+Synopses:
\newcommand{\CMD}[NARGS][OPTARGDEFAULT]{DEFN}
\newcommand*{\CMD}[NARGS][OPTARGDEFAULT]{DEFN}
\renewcommand{\CMD}[NARGS][OPTARGDEFAULT]{DEFN}
\renewcommand*{\CMD}[NARGS][OPTARGDEFAULT]{DEFN}
+ Define or redefine a command. See also the discussion of
+'\DeclareRobustCommand' in *note Class and package commands::.
+
The starred form of these two commands requires that the arguments
not contain multiple paragraphs of text (not '\long', in plain TeX
terms).
CMD
- Required; '\CMD' is the command name. For '\newcommand', it must
- not be already defined and must not begin with '\end'. For
- '\renewcommand', it must already be defined.
+ Required; the command name. It must begin with a backslash, '\',
+ and must not begin with '\end'. For '\newcommand', it must not be
+ already defined. For '\renewcommand', this name must already be
+ defined.
+
NARGS
Optional; an integer from 0 to 9, specifying the number of
arguments that the command can take, including any optional
@@ -5340,6 +5368,12 @@
Redefining an existing command is similar:
'\renewcommand{\qedsymbol}{{\small QED}}'.
+ If you try to define a command and the name has already been used
+then you get something like 'LaTeX Error: Command \fred already defined.
+Or name \end... illegal, see p.192 of the manual'. If you try to
+redefine a command and the name has not yet been used then you get
+something like 'LaTeX Error: \hank undefined'.
+
Here's a command definition with one required argument:
\newcommand{\defref}[1]{Definition~\ref{#1}}
@@ -5428,10 +5462,10 @@
\newlength{\ARG}
This command takes one required argument, which must begin with a
-backslash ('\'). It creates a new length register named '\ARG', which
-is a place to hold (rubber) lengths such as '1in plus.2in minus.1in'
-(what plain TeX calls a 'skip' register). The register gets an initial
-value of zero. The control sequence '\ARG' must not already be defined.
+backslash, '\'. It creates a new length register named '\ARG', which is
+a place to hold (rubber) lengths such as '1in plus.2in minus.1in' (what
+plain TeX calls a 'skip' register). The register gets an initial value
+of zero. The control sequence '\ARG' must not already be defined.
*Note Lengths::, for more about lengths.
@@ -5448,7 +5482,7 @@
Defines '\CMD' to refer to a new bin for storing boxes. Such a box
is for holding typeset material, to use multiple times (*note Boxes::)
or to measure or manipulate. The name '\CMD' must start with a
-backslash ('\'), and must not be already defined.
+backslash, '\', and must not be already defined.
The allocation of a box is global. This command is fragile (*note
\protect::).
@@ -5459,21 +5493,23 @@
12.6 '\newenvironment' & '\renewenvironment'
============================================
-These commands define or redefine an environment ENV, that is,
-'\begin{ENV} BODY \end{ENV}'. Synopses:
+Synopses:
- \newenvironment{ENV}[NARGS][OPTARGDEFAULT]{BEGDEFN}{ENDDEFN}
- \newenvironment*{ENV}[NARGS][OPTARGDEFAULT]{BEGDEFN}{ENDDEFN}
- \renewenvironment{ENV}[NARGS][OPTARGDEFAULT]{BEGDEFN}{ENDDEFN}
- \renewenvironment*{ENV}[NARGS][OPTARGDEFAULT]{BEGDEFN}{ENDDEFN}
+ \newenvironment{ENV}[NARGS][OPTARGDEFAULT]{BEGDEF}{ENDDEF}
+ \newenvironment*{ENV}[NARGS][OPTARGDEFAULT]{BEGDEF}{ENDDEF}
+ \renewenvironment{ENV}[NARGS][OPTARGDEFAULT]{BEGDEF}{ENDDEF}
+ \renewenvironment*{ENV}[NARGS][OPTARGDEFAULT]{BEGDEF}{ENDDEF}
+ Define or redefine the environment ENV, that is, create the construct
+'\begin{ENV} BODY \end{ENV}'.
+
The starred form of these commands requires that the arguments not
contain multiple paragraphs of text. The body of these environments can
still contain multiple paragraphs.
ENV
Required; the environment name. It consists only of letters or the
- '*' character, and thus does not begin with backslash ('\'). It
+ '*' character, and thus does not begin with backslash, '\'. It
must not begin with the string 'end'. For '\newenvironment', the
name ENV must not be the name of an already existing environment,
and also the command '\ENV' must be undefined. For
@@ -5483,11 +5519,11 @@
NARGS
Optional; an integer from 0 to 9 denoting the number of arguments
of that the environment will take. When the environment is used
- these arguments appear after the '\begin', as in
- '\begin{ENV}{ARG1}...{ARGN}'. If this argument is not present then
- the default is for the environment to have no arguments. When
- redefining an environment, the new version can have a different
- number of arguments than the old version.
+ these arguments appear after the '\begin', as in '\begin{ENV}{ARG1}
+ .... {ARGN}'. If this argument is not present then the default is
+ for the environment to have no arguments. When redefining an
+ environment, the new version can have a different number of
+ arguments than the old version.
OPTARGDEFAULT
Optional; if this argument is present then the first argument of
@@ -5510,21 +5546,27 @@
expanding to OPTARGDEFAULT; the latter results in '#1' expanding to
the empty string.
-BEGDEFN
+BEGDEF
Required; the text expanded at every occurrence of '\begin{ENV}'.
- Within BEGDEF, the Nth positional parameter (i.e., '#N') is
- replaced by the text of the Nth argument.
+ Within BEGDEF, the Nth positional parameter (i.e., '#1', '#2',
+ etc.) is replaced by the text of the Nth argument.
-ENDDEFN
+ENDDEF
Required; the text expanded at every occurrence of '\end{ENV}'.
- This may not contain any positional parameters, so '#N' cannot be
- used here (but see the final example below).
+ This may not contain any positional parameters, so you cannot use
+ '#1', '#2', etc., here (but see the final example below).
- All environments, that is to say the BEGDEFN code, the environment
-body and the ENDDEFN code, are processed within a group. Thus, in the
+ All environments, that is to say the BEGDEF code, the environment
+body, and the ENDDEF code, are processed within a group. Thus, in the
first example below, the effect of the '\small' is limited to the quote
and does not extend to material following the environment.
+ If you try to define an environment and the name has already been
+used then you get something like 'LaTeX Error: Command \fred already
+defined. Or name \end... illegal, see p.192 of the manual'. If you try
+to redefine an environment and the name has not yet been used then you
+get something like 'LaTeX Error: Environment hank undefined.'.
+
This example gives an environment like LaTeX's 'quotation' except
that it will be set in smaller type:
@@ -5552,7 +5594,7 @@
\end{citequote}
The final example shows how to save the value of an argument to use
-in ENDDEFN, in this case in a box (*note \sbox::):
+in ENDDEF, in this case in a box (*note \sbox::):
\newsavebox{\quoteauthor}
\newenvironment{citequote}[1][Shakespeare]{%
@@ -5569,23 +5611,23 @@
12.7 '\newtheorem'
==================
-Define a new theorem-like environment. Synopses:
+Synopses:
\newtheorem{NAME}{TITLE}
\newtheorem{NAME}{TITLE}[NUMBERED_WITHIN]
\newtheorem{NAME}[NUMBERED_LIKE]{TITLE}
- Using the first form, '\newtheorem{NAME}{TITLE}' creates an
-environment that will be labelled with TITLE. See the first example
-below.
+ Define a new theorem-like environment. The first form,
+'\newtheorem{NAME}{TITLE}', creates an environment that will be labelled
+with TITLE; see the first example below.
- The second form '\newtheorem{NAME}{TITLE}[NUMBERED_WITHIN]' creates
+ The second form, '\newtheorem{NAME}{TITLE}[NUMBERED_WITHIN]', creates
an environment whose counter is subordinate to the existing counter
-NUMBERED_WITHIN (its counter will be reset when NUMBERED_WITHIN is
-reset).
+NUMBERED_WITHIN, so this counter will be reset when NUMBERED_WITHIN is
+reset.
The third form '\newtheorem{NAME}[NUMBERED_LIKE]{TITLE}', with
-optional argument between the two required arguments, will create an
+optional argument between the two required arguments, creates an
environment whose counter will share the previously defined counter
NUMBERED_LIKE.
@@ -5602,13 +5644,13 @@
Arguments:
NAME
- The name of the environment. It must not begin with a backslash
- ('\'). It must not be the name of an existing environment; indeed,
- the command name '\NAME' must not already be defined as anything.
+ The name of the environment. It must not begin with a backslash,
+ '\'. It must not be the name of an existing environment, and the
+ command name '\NAME' must not already be defined.
TITLE
- The text printed at the beginning of the environment, before the
- number. For example, 'Theorem'.
+ The text to be printed at the beginning of the environment, before
+ the number. For example, 'Theorem'.
NUMBERED_WITHIN
Optional; the name of an already defined counter, usually a
@@ -5684,33 +5726,30 @@
12.8 '\newfont': Define a new font (obsolete)
=============================================
-'\newfont', now obsolete, defines a command that will switch fonts.
-Synopsis:
+This command is obsolete. This description is here only to help with
+old documents. New document should define fonts in families through the
+New Font Selection Scheme which allows you to, for example, associate a
+boldface with a roman (*note Fonts::).
+ Synopsis:
+
\newfont{\CMD}{FONT DESCRIPTION}
- This defines a control sequence '\CMD' that will change the current
-font. LaTeX will look on your system for a file named 'FONTNAME.tfm'.
-The control sequence must must not already be defined. It must begin
-with a backslash ('\').
+ Define a command '\CMD' that will change the current font. The
+control sequence must must not already be defined. It must begin with a
+backslash, '\'.
- This command is obsolete. It is a low-level command for setting up
-an individual font. Today fonts are almost always defined in families
-(which allows you to, for example, associate a boldface with a roman)
-through the so-called "New Font Selection Scheme", either by using '.fd'
-files or through the use of an engine that can access system fonts such
-as XeLaTeX (*note TeX engines::).
+ The FONT DESCRIPTION consists of a FONTNAME and an optional "at
+clause". LaTeX will look on your system for a file named
+'FONTNAME.tfm'. The at clause can have the form either 'at DIMEN' or
+'scaled FACTOR', where a FACTOR of '1000' means no scaling. For LaTeX's
+purposes, all this does is scale all the character and other font
+dimensions relative to the font's design size, which is a value defined
+in the '.tfm' file.
- But since it is part of LaTeX, here is an explanation: the FONT
-DESCRIPTION consists of a FONTNAME and an optional "at clause"; this can
-have the form either 'at DIMEN' or 'scaled FACTOR', where a FACTOR of
-'1000' means no scaling. For LaTeX's purposes, all this does is scale
-all the character and other font dimensions relative to the font's
-design size, which is a value defined in the '.tfm' file.
+ This defines two equivalent fonts and typesets a few characters in
+each.
- This example defines two equivalent fonts and typesets a few
-characters in each:
-
\newfont{\testfontat}{cmb10 at 11pt}
\newfont{\testfontscaled}{cmb10 scaled 1100}
\testfontat abc
@@ -5966,7 +6005,7 @@
value be the current 'ref' value (*note \ref::). This command is
fragile (*note \protect::).
- Put in the docuemnt preamble, this example makes a new list
+ Put in the document preamble, this example makes a new list
environment enumerated with TESTCOUNTER:
\newcounter{testcounter}
@@ -8829,14 +8868,14 @@
graphic.
The behavior of file system search code is necessarily platform
-dependent. In this document we cover Linux, Macintosh, and Windows, as
-those systems are typically configured. For other situations consult
+dependent. In this document we cover GNU/Linux, Macintosh, and Windows,
+as those systems are typically configured. For other situations consult
the documentation in 'grfguide.pdf', or the LaTeX source, or your TeX
distribution's documentation.
* Menu:
-* \graphicspath:: Directories to search.
+* \graphicspath:: Directories to search.
* \DeclareGraphicsExtensions:: File types, such as JPG or EPS.
* \DeclareGraphicsRule:: How to handle file types.
@@ -8934,9 +8973,9 @@
extensions then it reports '! LaTeX Error: File `'lion'' not found'.
Note that you must include the periods at the start of the extensions.
- Because Linux and Macintosh filenames are case sensitive, the list of
-file extensions is case sensitive on those platforms. The Windows
-platform is not case sensitive.
+ Because GNU/Linux and Macintosh filenames are case sensitive, the
+list of file extensions is case sensitive on those platforms. The
+Windows platform is not case sensitive.
You are not required to include '\DeclareGraphicsExtensions' in your
document; the printer driver has a sensible default. For example, the
@@ -10105,7 +10144,7 @@
We the People of the United States, in Order to form a more perfect Union, ...
Running LaTeX on 'constitution.tex' makes the material from the three
-files appear in the document but also generates the auxillary files
+files appear in the document but also generates the auxiliary files
'preamble.aux', 'articles.aux', and 'amendments.tex'. These contain
information such as page numbers and cross-references (*note Cross
references::). If you now comment out '\includeonly''s lines with
@@ -10133,8 +10172,8 @@
To make your document portable across distributions and platforms you
should avoid spaces in the file names. The tradition is to instead use
-underscores. That said, for the name ''amo amas amat'', this works
-under TeX Live on Linux
+dashes or underscores. Nevertheless, for the name 'amo amas amat', this
+works under TeX Live on GNU/Linux:
\documentclass{book}
\includeonly{
@@ -10144,7 +10183,7 @@
\include{"amo\space amas\space amat"}
\end{document}
- and this works under MiKTeX on Windows.
+ and this works under MiKTeX on Windows:
\documentclass{book}
\includeonly{
@@ -10188,7 +10227,7 @@
If FILE does not end in '.tex' then LaTeX first tries the filename with
that extension, so '\include{macros}' will cause LaTeX to first look for
'macros.tex'; this is the usual case. If there is no such file then the
-system tries the original file name, here ''macros'', without an
+system tries the original file name, here 'macros', without an
extension. (This may vary by distribution.)
@@ -10898,10 +10937,10 @@
* * prompt: Command line. (line 18)
* *-form of environment commands: \newenvironment & \renewenvironment.
- (line 14)
+ (line 16)
* *-form of sectioning commands: Sectioning. (line 31)
* *-form, defining new commands: \newcommand & \renewcommand.
- (line 14)
+ (line 16)
* .glo file: Glossaries. (line 8)
* .idx file: Indexes. (line 9)
* .ind file: Indexes. (line 23)
@@ -10933,7 +10972,7 @@
* ASCII circumflex, in text: Text symbols. (line 64)
* ASCII tilde, in text: Text symbols. (line 67)
* asterisk, centered, in text: Text symbols. (line 70)
-* at clause, in font definitions: \newfont. (line 23)
+* at clause, in font definitions: \newfont. (line 19)
* author, for titlepage: \maketitle. (line 12)
* auxiliary file: Output files. (line 33)
* babel package: thebibliography. (line 29)
@@ -11024,6 +11063,7 @@
* class options <2>: Class and package commands.
(line 66)
* classes of documents: Document classes. (line 6)
+* cleveref package: Cross references. (line 38)
* closing letters: \closing. (line 6)
* closing quote: Text symbols. (line 55)
* code, typesetting: verbatim. (line 6)
@@ -11094,7 +11134,7 @@
* defining new theorems: \newtheorem. (line 6)
* definitions: Definitions. (line 6)
* description lists, creating: description. (line 6)
-* design size, in font definitions: \newfont. (line 23)
+* design size, in font definitions: \newfont. (line 19)
* Didot point: Units of length. (line 30)
* dieresis accent: Accents. (line 16)
* difference between class and package: Class and package construction.
@@ -11221,7 +11261,7 @@
* footnotes, symbols instead of numbers: \footnote. (line 23)
* formulas, environment for: equation. (line 6)
* formulas, math: Math formulas. (line 6)
-* forward reference: Cross references. (line 22)
+* forward reference: Cross references. (line 27)
* forward references, resolving: Output files. (line 33)
* fragile commands: \protect. (line 6)
* French quotation marks: Text symbols. (line 30)
@@ -11305,7 +11345,7 @@
* justification, ragged left: \raggedleft. (line 6)
* justification, ragged right: \raggedright. (line 6)
* Knuth, Donald E.: Overview. (line 6)
-* label: Cross references. (line 9)
+* label: Cross references. (line 6)
* labelled lists, creating: description. (line 6)
* Lamport TeX: Overview. (line 24)
* Lamport, Leslie: Overview. (line 6)
@@ -11477,6 +11517,7 @@
* package, amsmath <1>: displaymath. (line 22)
* package, babel: thebibliography. (line 29)
* package, babel <1>: Accents. (line 6)
+* package, cleveref: Cross references. (line 38)
* package, datetime: \today. (line 22)
* package, enumitem: list. (line 24)
* package, etoolbox: Class and package commands.
@@ -11553,7 +11594,7 @@
(line 60)
* position, in picture: picture. (line 71)
* positional parameter: \newcommand & \renewcommand.
- (line 37)
+ (line 41)
* postscript, in letters: \ps. (line 6)
* pounds symbol: Text symbols. (line 48)
* preamble, defined: Starting and ending. (line 19)
@@ -11576,7 +11617,7 @@
* ragged right text, environment for: flushleft. (line 6)
* redefining environments: \newenvironment & \renewenvironment.
(line 6)
-* reference, forward: Cross references. (line 22)
+* reference, forward: Cross references. (line 27)
* references, resolving forward: Output files. (line 33)
* registered symbol: Text symbols. (line 163)
* remarks in the margin: Marginal notes. (line 6)
@@ -11658,7 +11699,7 @@
(line 10)
* star-variants, commands: \@ifstar. (line 6)
* starred form, defining new commands: \newcommand & \renewcommand.
- (line 14)
+ (line 16)
* starting a new page: \newpage. (line 6)
* starting a new page and clearing floats: \clearpage. (line 6)
* starting and ending: Starting and ending. (line 6)
@@ -11779,7 +11820,6 @@
* --help command-line option: Command line. (line 14)
* .aux file: Output files. (line 33)
* .dvi file: Output files. (line 10)
-* .fd file: \newfont. (line 16)
* .lof file: Output files. (line 43)
* .lof file <1>: Tables of contents. (line 16)
* .log file: Output files. (line 28)
@@ -13027,241 +13067,241 @@
Node: Low-level font commands53453
Node: Layout58560
Node: \onecolumn59058
-Node: \twocolumn59389
-Node: \flushbottom63784
-Node: \raggedbottom64884
-Node: Page layout parameters65420
-Node: Floats71118
-Node: Sectioning77583
-Ref: Sectioning/secnumdepth78904
-Node: \@startsection79314
-Ref: \@startsection/name80586
-Ref: \@startsection/level81046
-Ref: \@startsection/indent82117
-Ref: \@startsection/beforeskip82380
-Ref: \@startsection/afterskip83901
-Ref: \@startsection/style85212
-Node: Cross references89048
-Node: \label90914
-Node: \pageref92461
-Node: \ref93131
-Node: Environments93820
-Node: abstract95823
-Node: array97412
-Node: center99670
-Node: \centering101311
-Node: description102683
-Node: displaymath104870
-Node: document106648
-Node: \AtBeginDocument107078
-Node: \AtEndDocument107702
-Node: enumerate108346
-Node: eqnarray111143
-Node: equation113197
-Node: figure113867
-Node: filecontents115679
-Node: flushleft117432
-Node: \raggedright117925
-Node: flushright118484
-Node: \raggedleft118982
-Node: itemize119539
-Node: letter123040
-Node: list123278
-Node: \item135989
-Node: trivlist137242
-Node: math138770
-Node: minipage139076
-Node: picture140268
-Node: \circle145284
-Node: \makebox (picture)145627
-Node: \framebox (picture)146333
-Node: \dashbox146823
-Node: \frame147346
-Node: \line147672
-Node: \linethickness148130
-Node: \thicklines148551
-Node: \thinlines148861
-Node: \multiput149163
-Node: \oval149530
-Node: \put150251
-Node: \shortstack150542
-Node: \vector151016
-Node: quotation and quote151330
-Node: tabbing152537
-Node: table158475
-Node: tabular159902
-Node: \multicolumn167110
-Node: \vline170995
-Node: \cline172340
-Node: \hline173024
-Node: thebibliography173707
-Node: \bibitem175321
-Node: \cite176079
-Node: \nocite176598
-Node: Using BibTeX176886
-Node: theorem178395
-Node: titlepage178781
-Node: verbatim180071
-Node: \verb180710
-Node: verse181260
-Node: Line breaking181754
-Node: \\182851
-Node: \obeycr & \restorecr183889
-Node: \newline184291
-Node: \- (hyphenation)185125
-Node: \discretionary185740
-Node: \fussy186032
-Node: \sloppy186422
-Node: \hyphenation186749
-Node: \linebreak & \nolinebreak187374
-Node: Page breaking188026
-Node: \cleardoublepage188634
-Node: \clearpage189063
-Node: \newpage189360
-Node: \enlargethispage189591
-Node: \pagebreak & \nopagebreak190118
-Node: Footnotes190812
-Node: \footnote192066
-Node: \footnotemark193862
-Node: \footnotetext195106
-Node: Footnotes in a table195596
-Node: Footnotes in section headings197453
-Node: Footnotes of footnotes198309
-Node: Multiple reference to footnotes199076
-Node: Footnote parameters199934
-Node: Definitions200684
-Node: \newcommand & \renewcommand201561
-Node: \providecommand205397
-Node: \newcounter206058
-Node: \newlength207209
-Node: \newsavebox207856
-Node: \newenvironment & \renewenvironment208467
-Node: \newtheorem212827
-Node: \newfont216316
-Node: \protect217881
-Node: \ignorespaces & \ignorespacesafterend220267
-Node: Counters223016
-Node: \alph \Alph \arabic \roman \Roman \fnsymbol224689
-Node: \usecounter227518
-Node: \value228381
-Node: \setcounter229310
-Node: \addtocounter229912
-Node: \refstepcounter230377
-Node: \stepcounter231035
-Node: \day \month \year231377
-Node: Lengths231922
-Node: Units of length233712
-Node: \setlength235206
-Node: \addtolength235610
-Node: \settodepth235928
-Node: \settoheight236219
-Node: \settowidth236516
-Node: Predefined lengths236824
-Node: Making paragraphs237339
-Node: \indent237911
-Node: \noindent238373
-Node: \parskip238882
-Node: Marginal notes239140
-Node: Math formulas240952
-Node: Subscripts & superscripts242736
-Node: Math symbols244074
-Node: Math functions269403
-Node: Math accents270346
-Node: Spacing in math mode271318
-Node: Math miscellany272785
-Node: Modes275335
-Node: \ensuremath277175
-Node: Page styles278091
-Node: \maketitle278585
-Node: \pagenumbering279655
-Node: \pagestyle280151
-Node: \thispagestyle281292
-Node: Spaces281598
-Node: \hspace282468
-Node: \hfill283423
-Node: \spacefactor283815
-Node: \(SPACE) and \@286527
-Ref: \AT286670
-Node: \frenchspacing288147
-Node: \normalsfcodes288763
-Node: \(SPACE) after control sequence288952
-Node: \thinspace289863
-Node: \/290183
-Node: \hrulefill \dotfill291365
-Node: \addvspace292358
-Node: \bigskip \medskip \smallskip293404
-Node: \vfill294296
-Node: \vspace295165
-Node: Boxes296158
-Node: \mbox296870
-Node: \fbox and \framebox297157
-Node: lrbox297961
-Node: \makebox298319
-Node: \parbox299039
-Node: \raisebox300607
-Node: \savebox301204
-Node: \sbox301619
-Node: \usebox302068
-Node: Color302329
-Node: Color package options303173
-Node: Color models304819
-Node: Commands for color307128
-Node: Define colors307543
-Node: Colored text308258
-Node: Colored boxes310633
-Node: Colored pages312072
-Node: Graphics312765
-Node: Graphics package options314884
-Node: Graphics package configuration317640
-Node: \graphicspath318431
-Node: \DeclareGraphicsExtensions321354
-Node: \DeclareGraphicsRule323147
-Node: Commands for graphics326336
-Node: \includegraphics326841
-Node: \rotatebox339867
-Node: \scalebox342662
-Node: \resizebox343714
-Node: Special insertions344906
-Node: Reserved characters345710
-Node: Upper and lower case346911
-Node: Symbols by font position348826
-Node: Text symbols349446
-Node: Accents352894
-Node: Additional Latin letters355436
-Ref: Non-English characters355607
-Node: \rule356624
-Node: \today357053
-Node: Splitting the input357807
-Node: \endinput359184
-Node: \include & \includeonly360451
-Node: \input364452
-Node: Front/back matter365162
-Node: Tables of contents365367
-Node: \addcontentsline366428
-Node: \addtocontents367446
-Node: Glossaries367979
-Node: Indexes368498
-Node: Letters370131
-Node: \address373809
-Node: \cc374679
-Node: \closing375097
-Node: \encl375408
-Node: \location375823
-Node: \makelabels376092
-Node: \name377093
-Node: \opening377323
-Node: \ps377663
-Node: \signature377952
-Node: \telephone379044
-Node: Terminal input/output379409
-Node: \typein379674
-Node: \typeout380259
-Node: Command line380882
-Node: Document templates381834
-Node: beamer template382241
-Node: book template382892
-Node: tugboat template383260
-Node: Concept Index385624
-Node: Command Index448461
+Node: \twocolumn59420
+Node: \flushbottom63815
+Node: \raggedbottom64915
+Node: Page layout parameters65451
+Node: Floats71149
+Node: Sectioning77614
+Ref: Sectioning/secnumdepth78935
+Node: \@startsection79345
+Ref: \@startsection/name80617
+Ref: \@startsection/level81077
+Ref: \@startsection/indent82148
+Ref: \@startsection/beforeskip82411
+Ref: \@startsection/afterskip83932
+Ref: \@startsection/style85243
+Node: Cross references89079
+Node: \label91212
+Node: \pageref93009
+Node: \ref93809
+Node: Environments94686
+Node: abstract96689
+Node: array98278
+Node: center100536
+Node: \centering102177
+Node: description103549
+Node: displaymath105736
+Node: document107514
+Node: \AtBeginDocument107944
+Node: \AtEndDocument108568
+Node: enumerate109212
+Node: eqnarray112009
+Node: equation114063
+Node: figure114733
+Node: filecontents116545
+Node: flushleft118298
+Node: \raggedright118791
+Node: flushright119350
+Node: \raggedleft119848
+Node: itemize120405
+Node: letter123906
+Node: list124144
+Node: \item136855
+Node: trivlist138108
+Node: math139636
+Node: minipage139942
+Node: picture141134
+Node: \circle146150
+Node: \makebox (picture)146493
+Node: \framebox (picture)147199
+Node: \dashbox147689
+Node: \frame148212
+Node: \line148538
+Node: \linethickness148996
+Node: \thicklines149417
+Node: \thinlines149727
+Node: \multiput150029
+Node: \oval150396
+Node: \put151117
+Node: \shortstack151408
+Node: \vector151882
+Node: quotation and quote152196
+Node: tabbing153403
+Node: table159341
+Node: tabular160768
+Node: \multicolumn167976
+Node: \vline171861
+Node: \cline173206
+Node: \hline173890
+Node: thebibliography174573
+Node: \bibitem176187
+Node: \cite176945
+Node: \nocite177464
+Node: Using BibTeX177752
+Node: theorem179261
+Node: titlepage179647
+Node: verbatim180937
+Node: \verb181576
+Node: verse182126
+Node: Line breaking182620
+Node: \\183717
+Node: \obeycr & \restorecr184755
+Node: \newline185157
+Node: \- (hyphenation)185991
+Node: \discretionary186606
+Node: \fussy186898
+Node: \sloppy187288
+Node: \hyphenation187615
+Node: \linebreak & \nolinebreak188240
+Node: Page breaking188892
+Node: \cleardoublepage189500
+Node: \clearpage189929
+Node: \newpage190226
+Node: \enlargethispage190457
+Node: \pagebreak & \nopagebreak190984
+Node: Footnotes191678
+Node: \footnote192932
+Node: \footnotemark194728
+Node: \footnotetext195972
+Node: Footnotes in a table196462
+Node: Footnotes in section headings198319
+Node: Footnotes of footnotes199175
+Node: Multiple reference to footnotes199942
+Node: Footnote parameters200800
+Node: Definitions201550
+Node: \newcommand & \renewcommand202427
+Node: \providecommand206673
+Node: \newcounter207334
+Node: \newlength208485
+Node: \newsavebox209131
+Node: \newenvironment & \renewenvironment209741
+Node: \newtheorem214472
+Node: \newfont217945
+Node: \protect219240
+Node: \ignorespaces & \ignorespacesafterend221626
+Node: Counters224375
+Node: \alph \Alph \arabic \roman \Roman \fnsymbol226048
+Node: \usecounter228877
+Node: \value229740
+Node: \setcounter230669
+Node: \addtocounter231271
+Node: \refstepcounter231736
+Node: \stepcounter232394
+Node: \day \month \year232736
+Node: Lengths233281
+Node: Units of length235071
+Node: \setlength236565
+Node: \addtolength236969
+Node: \settodepth237287
+Node: \settoheight237578
+Node: \settowidth237875
+Node: Predefined lengths238183
+Node: Making paragraphs238698
+Node: \indent239270
+Node: \noindent239732
+Node: \parskip240241
+Node: Marginal notes240499
+Node: Math formulas242311
+Node: Subscripts & superscripts244095
+Node: Math symbols245433
+Node: Math functions270762
+Node: Math accents271705
+Node: Spacing in math mode272677
+Node: Math miscellany274144
+Node: Modes276694
+Node: \ensuremath278534
+Node: Page styles279450
+Node: \maketitle279944
+Node: \pagenumbering281014
+Node: \pagestyle281510
+Node: \thispagestyle282651
+Node: Spaces282957
+Node: \hspace283827
+Node: \hfill284782
+Node: \spacefactor285174
+Node: \(SPACE) and \@287886
+Ref: \AT288029
+Node: \frenchspacing289506
+Node: \normalsfcodes290122
+Node: \(SPACE) after control sequence290311
+Node: \thinspace291222
+Node: \/291542
+Node: \hrulefill \dotfill292724
+Node: \addvspace293717
+Node: \bigskip \medskip \smallskip294763
+Node: \vfill295655
+Node: \vspace296524
+Node: Boxes297517
+Node: \mbox298229
+Node: \fbox and \framebox298516
+Node: lrbox299320
+Node: \makebox299678
+Node: \parbox300398
+Node: \raisebox301966
+Node: \savebox302563
+Node: \sbox302978
+Node: \usebox303427
+Node: Color303688
+Node: Color package options304532
+Node: Color models306178
+Node: Commands for color308487
+Node: Define colors308902
+Node: Colored text309617
+Node: Colored boxes311992
+Node: Colored pages313431
+Node: Graphics314124
+Node: Graphics package options316243
+Node: Graphics package configuration318999
+Node: \graphicspath319801
+Node: \DeclareGraphicsExtensions322724
+Node: \DeclareGraphicsRule324521
+Node: Commands for graphics327710
+Node: \includegraphics328215
+Node: \rotatebox341241
+Node: \scalebox344036
+Node: \resizebox345088
+Node: Special insertions346280
+Node: Reserved characters347084
+Node: Upper and lower case348285
+Node: Symbols by font position350200
+Node: Text symbols350820
+Node: Accents354268
+Node: Additional Latin letters356810
+Ref: Non-English characters356981
+Node: \rule357998
+Node: \today358427
+Node: Splitting the input359181
+Node: \endinput360558
+Node: \include & \includeonly361825
+Node: \input365842
+Node: Front/back matter366550
+Node: Tables of contents366755
+Node: \addcontentsline367816
+Node: \addtocontents368834
+Node: Glossaries369367
+Node: Indexes369886
+Node: Letters371519
+Node: \address375197
+Node: \cc376067
+Node: \closing376485
+Node: \encl376796
+Node: \location377211
+Node: \makelabels377480
+Node: \name378481
+Node: \opening378711
+Node: \ps379051
+Node: \signature379340
+Node: \telephone380432
+Node: Terminal input/output380797
+Node: \typein381062
+Node: \typeout381647
+Node: Command line382270
+Node: Document templates383222
+Node: beamer template383629
+Node: book template384280
+Node: tugboat template384648
+Node: Concept Index387012
+Node: Command Index449995
End Tag Table
Modified: trunk/latex2e.pdf
===================================================================
(Binary files differ)
Modified: trunk/latex2e.texi
===================================================================
--- trunk/latex2e.texi 2018-05-19 14:07:46 UTC (rev 623)
+++ trunk/latex2e.texi 2018-05-19 19:34:10 UTC (rev 624)
@@ -22,6 +22,7 @@
@c xx merge display style math
@c xx vertical mode, horizontal mode
@c xx JH Discuss restricted execution
+ at c xx explain nfss somewhere
@c
@c xx The typeset source2e has an index with all kernel
@c xx commands, though some are internal and shouldn't be included.
@@ -1968,6 +1969,12 @@
@findex \onecolumn
@cindex one-column output
+Synopsis:
+
+ at example
+\onecolumn
+ at end example
+
Start a new page and produce single-column output. If the document is
given the class option @code{onecolumn} then this is the default
behavior (@pxref{Document class options}).
@@ -2805,39 +2812,50 @@
@cindex cross references
-One reason for numbering things such as figures and equations is to
-refer the reader to them, as in ``See Figure~3 for more details.''
-
@cindex label
-Including the figure number in the source is poor practice since if that
-number changes as the document evolves then you must remember to update
-this reference by hand. Instead, @LaTeX{} has you write a @dfn{label}
-like @code{\label@{eq:GreensThm@}} and refer to it with @code{See
-equation~\ref@{eq:GreensThm@}}.
+We often want something like @samp{See Theorem~31}. But by-hand typing
+the 31 is poor practice. Instead you should write a @dfn{label} such as
+ at code{\label@{eq:GreensThm@}} and then @dfn{reference} it, as with
+ at code{See equation~\ref@{eq:GreensThm@}}. @LaTeX{} will automatically
+work out the number, put it into the output, and will change that number
+later if needed.
- at LaTeX{} writes the information from the labels to a file with the same
-name as the file containing the @code{\label@{...@}} but with an
- at file{.aux} extension. (The information has the format
- at code{\newlabel@{@var{label}@}@{@{@var{currentlabel}@}@{@var{pagenumber}@}@}}
-where @var{currentlabel} is the current value of the macro
- at code{\@@currentlabel} that is usually updated whenever you call
- at code{\refstepcounter@{@var{counter}@}}.)
+ at example
+We will later see this with Theorem~\ref@{th:GreensThm@}. % This is a forward reference
+...
+\begin@{theorem@} \label@{th:GreensThm@}
+ ...
+\end@{theorem@}
+...
+See Theorem~\ref@{th:GreensThm@} on page~\pageref@{th:GreensThm@}.
+ at end example
+ at LaTeX{} tracks cross reference information in a file having the
+extension @file{.aux} and with the same base name as the file containing
+the @code{\label}. So if @code{\label} is in @file{calculus.tex} then
+the information is in @file{calculus.aux}. @LaTeX{} puts the
+information in that file every time it across a @code{\label}.
+
@cindex forward reference
@cindex reference, forward
-The most common side effect of the prior paragraph happens when your
-document has a @dfn{forward reference}, a @code{\ref@{@var{key}@}} that
-appears earlier than the associated @code{\label@{@var{key}@}}; see the
-example in the @code{\pageref@{...@}} description. @LaTeX{} gets the
-information for references from the @file{.aux} file. If this is the
-first time you are compiling the document then you will get a message
- at code{LaTeX Warning: Label(s) may have changed. Rerun to get
-cross references right.} and in the output the reference will appear as
-two question marks at tie{}@samp{??}, in boldface. Or, if you change some
-things so the references change then you get the same warning and the
-output contains the old reference information. The solution in either
-case is just to compile the document a second time.
+The behavior described in the prior paragraph results in a quirk that
+happens when your document has a @dfn{forward reference}, a @code{\ref}
+that appears before the associated @code{\label}. If this is the first
+time that you are compiling the document then you will get @samp{LaTeX
+Warning: Label(s) may have changed. Rerun to get cross references right}
+and in the output the forward reference will appear as two question
+marks at tie{}@samp{??}, in boldface. A similar thing happens if you
+change some things so the references changes; you get the same warning
+and the output contains the old reference information. In both cases,
+to resolve this just compile the document a second time.
+ at PkgIndex{cleveref}
+The @code{cleveref} package enhances @LaTeX{}'s cross referencing
+features. You can have the format of the cross-references determined
+automatically according to the type of cross-reference, such as
+equation, section, etc., and the context in which you use that
+reference.
+
@menu
* \label:: Assign a symbolic name to a piece of text.
* \pageref:: Refer to a page number.
@@ -2889,11 +2907,17 @@
Thus, @code{\label@{fig:Euler@}} is a label for a figure with a portrait
of the great man.
-In this example below the key @code{sec:test} will get the number of the
-current section and the key @code{fig:test} will get the number of the
-figure. (Incidentally, put labels after captions in figures and
-tables.)
+Inside the auxillary file the reference information is kept in the
+format
+ at code{\newlabel@{@var{label}@}@{@{@var{currentlabel}@}@{@var{pagenumber}@}@}}.
+Here @var{currentlabel} is the current value of the macro
+ at code{\@@currentlabel} that is usually updated whenever you call
+ at code{\refstepcounter@{@var{counter}@}}.
+Below, the key @code{sec:test} will get the number of the current
+section and the key @code{fig:test} will get the number of the figure.
+(Incidentally, put labels after captions in figures and tables.)
+
@example
\section@{section name@}
\label@{sec:test@}
@@ -2923,11 +2947,15 @@
Produce the page number of the place in the text where the corresponding
@code{\label}@{@var{key}@} command appears.
-In this example the @code{\label@{eq:main@}} is used both for the
-formula number and for the page number. (Note that the two references
-are forward references, so this document would need to be compiled twice
-to resolve those.)
+If there is no @code{\label@{@var{key}@}} then you get something like
+ at samp{LaTeX Warning: Reference `th:GrensThm' on page 1 undefined on
+input line 11.}
+Below, the @code{\label@{eq:main@}} is used both for the formula number
+and for the page number. (Note that the two references are forward
+references so this document would need to be compiled twice to resolve
+those.)
+
@example
The main result is formula~\ref@{eq:main@} on page~\pageref@{eq:main@}.
...
@@ -2958,10 +2986,14 @@
@code{\label} command (@pxref{\label}). It does not produce any text,
such as the word `Section' or `Figure', just the bare number itself.
-In this example, the @code{\ref@{popular@}} produces @samp{2}. Note
-that it is a forward reference since it comes before
- at code{\label@{popular@}}.
+If there is no @code{\label@{@var{key}@}} then you get something like
+ at samp{LaTeX Warning: Reference `th:GrensThm' on page 1 undefined on
+input line 11.}
+In this example the @code{\ref@{popular@}} produces @samp{2}. Note that
+it is a forward reference since it comes before @code{\label@{popular@}}
+so this document would have to be compiled twice.
+
@example
The most widely-used format is item number~\ref@{popular@}.
\begin@{enumerate@}
@@ -6481,9 +6513,6 @@
@LaTeX{} has support for making new commands of many different kinds.
- at c xx everything in this chapter needs examples.
- at c xx Add DeclareRobustCommand (see clsguide.pdf)
-
@menu
* \newcommand & \renewcommand:: (Re)define a new command.
* \providecommand:: Define a new command, if name not used.
@@ -6507,8 +6536,7 @@
@cindex defining a new command
@cindex new commands, defining
- at code{\newcommand} and @code{\renewcommand} define and redefine a
-command, respectively. Synopses:
+Synopses:
@example
\newcommand@{\@var{cmd}@}[@var{nargs}][@var{optargdefault}]@{@var{defn}@}
@@ -6517,6 +6545,9 @@
\renewcommand*@{\@var{cmd}@}[@var{nargs}][@var{optargdefault}]@{@var{defn}@}
@end example
+Define or redefine a command. See also the discussion of
+ at code{\DeclareRobustCommand} in @ref{Class and package commands}.
+
@cindex starred form, defining new commands
@cindex *-form, defining new commands
The starred form of these two commands requires that the arguments not
@@ -6525,10 +6556,12 @@
@table @var
@item cmd
-Required; @code{\@var{cmd}} is the command name. For @code{\newcommand}, it
-must not be already defined and must not begin with @code{\end}. For
- at code{\renewcommand}, it must already be defined.
+Required; the command name. It must begin with a backslash, @code{\},
+and must not begin with @code{\end}. For @code{\newcommand}, it must
+not be already defined. For @code{\renewcommand}, this name must
+already be defined.
+
@item nargs
Optional; an integer from 0 to 9, specifying the number of arguments
that the command can take, including any optional argument. If this
@@ -6575,6 +6608,12 @@
Redefining an existing command is similar:
@code{\renewcommand@{\qedsymbol@}@{@{\small QED@}@}}.
+If you try to define a command and the name has already been used then
+you get something like @samp{LaTeX Error: Command \fred already
+defined. Or name \end... illegal, see p.192 of the manual}. If you try
+to redefine a command and the name has not yet been used then you get
+something like @samp{LaTeX Error: \hank undefined}.
+
Here's a command definition with one required argument:
@example
@@ -6688,7 +6727,7 @@
@end example
This command takes one required argument, which must begin with a
-backslash (@samp{\}). It creates a new length register named
+backslash, @code{\}. It creates a new length register named
@code{\@var{arg}}, which is a place to hold (rubber) lengths such as
@code{1in plus.2in minus.1in} (what plain @TeX{} calls a @code{skip}
register). The register gets an initial value of zero. The control
@@ -6709,11 +6748,10 @@
\newsavebox@{\@var{cmd}@}
@end example
-Defines @code{\@var{cmd}} to refer to a new bin for storing boxes.
-Such a box is for holding typeset material, to use multiple times
-(@pxref{Boxes}) or to measure or manipulate. The name
- at code{\@var{cmd}} must start with a backslash (@samp{\}), and must not
-be already defined.
+Defines @code{\@var{cmd}} to refer to a new bin for storing boxes. Such
+a box is for holding typeset material, to use multiple times
+(@pxref{Boxes}) or to measure or manipulate. The name @code{\@var{cmd}}
+must start with a backslash, @code{\}, and must not be already defined.
The allocation of a box is global. This command is fragile
(@pxref{\protect}).
@@ -6728,16 +6766,18 @@
@cindex defining new environments
@cindex redefining environments
-These commands define or redefine an environment @var{env}, that is,
- at code{\begin@{@var{env}@} @var{body} \end@{@var{env}@}}. Synopses:
+Synopses:
@example
- \newenvironment@{@var{env}@}[@var{nargs}][@var{optargdefault}]@{@var{begdefn}@}@{@var{enddefn}@}
- \newenvironment*@{@var{env}@}[@var{nargs}][@var{optargdefault}]@{@var{begdefn}@}@{@var{enddefn}@}
- \renewenvironment@{@var{env}@}[@var{nargs}][@var{optargdefault}]@{@var{begdefn}@}@{@var{enddefn}@}
-\renewenvironment*@{@var{env}@}[@var{nargs}][@var{optargdefault}]@{@var{begdefn}@}@{@var{enddefn}@}
+ \newenvironment@{@var{env}@}[@var{nargs}][@var{optargdefault}]@{@var{begdef}@}@{@var{enddef}@}
+ \newenvironment*@{@var{env}@}[@var{nargs}][@var{optargdefault}]@{@var{begdef}@}@{@var{enddef}@}
+ \renewenvironment@{@var{env}@}[@var{nargs}][@var{optargdefault}]@{@var{begdef}@}@{@var{enddef}@}
+\renewenvironment*@{@var{env}@}[@var{nargs}][@var{optargdefault}]@{@var{begdef}@}@{@var{enddef}@}
@end example
+Define or redefine the environment @var{env}, that is, create the
+construct @code{\begin@{@var{env}@} @var{body} \end@{@var{env}@}}.
+
@cindex @code{*}-form of environment commands
The starred form of these commands requires that the arguments not
contain multiple paragraphs of text. The body of these environments can
@@ -6746,8 +6786,8 @@
@table @var
@item env
Required; the environment name. It consists only of letters or the
- at code{*} character, and thus does not begin with backslash
-(@code{\}). It must not begin with the string @code{end}. For
+ at code{*} character, and thus does not begin with backslash, @code{\}.
+It must not begin with the string @code{end}. For
@code{\newenvironment}, the name @var{env} must not be the name of an
already existing environment, and also the command @code{\@var{env}}
must be undefined. For @code{\renewenvironment}, @var{env} must be the
@@ -6757,7 +6797,7 @@
Optional; an integer from 0 to 9 denoting the number of arguments of
that the environment will take. When the environment is used these
arguments appear after the @code{\begin}, as in
- at code{\begin@{@var{env}@}@{@var{arg1}@}@dots{}@{@var{argn}@}}. If this
+ at code{\begin@{@var{env}@}@{@var{arg1}@} .... @{@var{argn}@}}. If this
argument is not present then the default is for the environment to have
no arguments. When redefining an environment, the new version can have
a different number of arguments than the old version.
@@ -6783,25 +6823,31 @@
in @code{#1} expanding to @var{optargdefault}; the latter results in
@code{#1} expanding to the empty string.
- at item begdefn
+ at item begdef
Required; the text expanded at every occurrence of
@code{\begin@{@var{env}@}}. Within @var{begdef}, the @var{n}th
-positional parameter (i.e., @code{#@var{n}}) is replaced by the text
-of the @var{n}th argument.
+positional parameter (i.e., @code{#1}, @code{#2}, etc.) is replaced by
+the text of the @var{n}th argument.
- at item enddefn
+ at item enddef
Required; the text expanded at every occurrence of
@code{\end@{@var{env}@}}. This may not contain any positional
-parameters, so @code{#@var{n}} cannot be used here (but see the final
-example below).
+parameters, so you cannot use @code{#1}, @code{#2}, etc., here (but see
+the final example below).
@end table
-All environments, that is to say the @var{begdefn} code, the environment
-body and the @var{enddefn} code, are processed within a group. Thus, in
+All environments, that is to say the @var{begdef} code, the environment
+body, and the @var{enddef} code, are processed within a group. Thus, in
the first example below, the effect of the @code{\small} is limited to
the quote and does not extend to material following the environment.
+If you try to define an environment and the name has already been used
+then you get something like @samp{LaTeX Error: Command \fred already
+defined. Or name \end... illegal, see p.192 of the manual}. If you try
+to redefine an environment and the name has not yet been used then you
+get something like @samp{LaTeX Error: Environment hank undefined.}.
+
This example gives an environment like @LaTeX{}'s @code{quotation}
except that it will be set in smaller type:
@@ -6835,7 +6881,7 @@
@end example
The final example shows how to save the value of an argument to use in
- at var{enddefn}, in this case in a box (@pxref{\sbox}):
+ at var{enddef}, in this case in a box (@pxref{\sbox}):
@example
\newsavebox@{\quoteauthor@}
@@ -6858,7 +6904,7 @@
@cindex theorem-like environment
@cindex environment, theorem-like
-Define a new theorem-like environment. Synopses:
+Synopses:
@example
\newtheorem@{@var{name}@}@{@var{title}@}
@@ -6866,21 +6912,20 @@
\newtheorem@{@var{name}@}[@var{numbered_like}]@{@var{title}@}
@end example
-Using the first form, @code{\newtheorem@{@var{name}@}@{@var{title}@}}
-creates an environment that will be labelled with @var{title}. See the
-first example below.
+Define a new theorem-like environment. The first form,
+ at code{\newtheorem@{@var{name}@}@{@var{title}@}}, creates an environment
+that will be labelled with @var{title}; see the first example below.
-The second form
- at code{\newtheorem@{@var{name}@}@{@var{title}@}[@var{numbered_within}]}
+The second form,
+ at code{\newtheorem@{@var{name}@}@{@var{title}@}[@var{numbered_within}]},
creates an environment whose counter is subordinate to the existing
-counter @var{numbered_within} (its counter will be reset when
- at var{numbered_within} is reset).
+counter @var{numbered_within}, so this counter will be reset when
+ at var{numbered_within} is reset.
-
The third form
@code{\newtheorem@{@var{name}@}[@var{numbered_like}]@{@var{title}@}},
-with optional argument between the two required arguments, will create
-an environment whose counter will share the previously defined counter
+with optional argument between the two required arguments, creates an
+environment whose counter will share the previously defined counter
@var{numbered_like}.
You can specify one of @var{numbered_within} and @var{numbered_like},
@@ -6897,12 +6942,12 @@
@table @var
@item name
-The name of the environment. It must not begin with a backslash
-(@samp{\}). It must not be the name of an existing environment; indeed,
-the command name @code{\@var{name}} must not already be defined as anything.
+The name of the environment. It must not begin with a backslash,
+ at code{\}. It must not be the name of an existing environment, and
+the command name @code{\@var{name}} must not already be defined.
@item title
-The text printed at the beginning of the environment, before the
+The text to be printed at the beginning of the environment, before the
number. For example, @samp{Theorem}.
@item numbered_within
@@ -6990,39 +7035,37 @@
@cindex fonts, new commands for
@cindex defining new fonts
- at code{\newfont}, now obsolete, defines a command that will switch fonts.
+ at c @findex .fd @r{file}
+This command is obsolete. This description is here only to help with old
+documents. New document should define fonts in families through the New
+Font Selection Scheme which allows you to, for example, associate a
+boldface with a roman (@pxref{Fonts}).
+ at c This is done either by using
+ at c @file{.fd} files or through the use of an engine that can access system
+ at c fonts such as Xe at LaTeX{} (@pxref{@TeX{} engines}).
+
Synopsis:
@example
\newfont@{\@var{cmd}@}@{@var{font description}@}
@end example
-This defines a control sequence @code{\@var{cmd}} that will change the
-current font. @LaTeX{} will look on your system for a file named
- at file{@var{fontname}.tfm}. The control sequence must must not already
-be defined. It must begin with a backslash (@samp{\}).
+Define a command @code{\@var{cmd}} that will change the current font.
+The control sequence must must not already be defined. It must begin
+with a backslash, @code{\}.
- at findex .fd @r{file}
-This command is obsolete. It is a low-level command for setting up an
-individual font. Today fonts are almost always defined in families
-(which allows you to, for example, associate a boldface with a roman)
-through the so-called ``New Font Selection Scheme'', either by using
- at file{.fd} files or through the use of an engine that can access
-system fonts such as Xe at LaTeX{} (@pxref{@TeX{} engines}).
- at c xx explain nfss somewhere
-
@cindex at clause, in font definitions
@cindex design size, in font definitions
-But since it is part of @LaTeX{}, here is an explanation: the
- at var{font description} consists of a @var{fontname} and an optional
- at dfn{at clause}; this can have the form either @code{at @var{dimen}}
-or @code{scaled @var{factor}}, where a @var{factor} of @samp{1000}
-means no scaling. For @LaTeX{}'s purposes, all this does is scale all
-the character and other font dimensions relative to the font's design
-size, which is a value defined in the @file{.tfm} file.
+The @var{font description} consists of a @var{fontname} and an optional
+ at dfn{at clause}. @LaTeX{} will look on your system for a file named
+ at file{@var{fontname}.tfm}. The at clause can have the form either
+ at code{at @var{dimen}} or @code{scaled @var{factor}}, where a
+ at var{factor} of @samp{1000} means no scaling. For @LaTeX{}'s purposes,
+all this does is scale all the character and other font dimensions
+relative to the font's design size, which is a value defined in the
+ at file{.tfm} file.
-This example defines two equivalent fonts and typesets a few
-characters in each:
+This defines two equivalent fonts and typesets a few characters in each.
@example
\newfont@{\testfontat@}@{cmb10 at 11pt@}
More information about the latexrefman-commits
mailing list