summaryrefslogtreecommitdiff
path: root/Master/texmf-doc/doc/english/FAQ-en/html/FAQ-errmissitem.html
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-doc/doc/english/FAQ-en/html/FAQ-errmissitem.html')
-rw-r--r--Master/texmf-doc/doc/english/FAQ-en/html/FAQ-errmissitem.html60
1 files changed, 54 insertions, 6 deletions
diff --git a/Master/texmf-doc/doc/english/FAQ-en/html/FAQ-errmissitem.html b/Master/texmf-doc/doc/english/FAQ-en/html/FAQ-errmissitem.html
index 27f50e1bf25..cf7d29a3f68 100644
--- a/Master/texmf-doc/doc/english/FAQ-en/html/FAQ-errmissitem.html
+++ b/Master/texmf-doc/doc/english/FAQ-en/html/FAQ-errmissitem.html
@@ -2,7 +2,7 @@
<title>UK TeX FAQ -- question label errmissitem</title>
</head><body>
<h3>Perhaps a missing <code>\</code><code>item</code>?</h3>
-<p>Sometimes, the error
+<p/>Sometimes, the error
<blockquote>
<pre>
Something's wrong--perhaps a missing \item
@@ -17,7 +17,55 @@ actually means what it says:
</pre>
</blockquote><p>
produces the error, and is plainly in need of an <code>\</code><code>item</code> command.
-<p>However, the error regularly appears when you would never have thought
+<p/>You can also have the error appear when at first sight things are
+correct:
+<blockquote>
+<pre>
+\begin{tabular}{l}
+ \begin{enumerate}
+ \item foo\\
+ \item bar
+ \end{enumerate}
+\end{tabular}
+</pre>
+</blockquote><p>
+produces the error at the bsbs. This usage is just wrong; if you
+want to number the cells in a table, you have to do it &ldquo;by hand&rdquo;:
+<blockquote>
+<pre>
+\newcounter{tablecell}
+\begin{tabular}{l}
+ \stepcounter{tablecell}
+ \thetablecell. foo\\
+ \stepcounter{tablecell}
+ \thetablecell. bar
+ \end{enumerate}
+\end{tabular}
+</pre>
+</blockquote><p>
+This is obviously untidy; a command <code>\</code><code>numbercell</code> defined as:
+<blockquote>
+<pre>
+\newcounter{tablecell}
+\newcommand*{\numbercell}{%
+ \stepcounter{tablecell}%
+ \thetablecell. % **
+}
+</pre>
+</blockquote><p>
+could make life easier:
+<blockquote>
+<pre>
+\begin{tabular}{l}
+ \numbercell foo\\
+ \numbercell bar
+ \end{enumerate}
+\end{tabular}
+</pre>
+</blockquote><p>
+(Note the deliberate introduction of a space as part of the command,
+marked with asterisks.)
+<p/>However, the error regularly appears when you would never have thought
that a <code>\</code><code>item</code> command might be appropriate. For example, the
seemingly innocent:
<blockquote>
@@ -39,7 +87,7 @@ itself, in fact, so <code>\</code><code>begin{itemize}</code> won&rsquo;t work i
paragraphs, so it makes a new paragraph of its own. Inside the
<code>\</code><code>fbox</code> command, that doesn&rsquo;t work, and subsequent macros convince
themselves that there&rsquo;s a missing <code>\</code><code>item</code> command.
-<p>To solve this rather cryptic error, one must put the
+<p/>To solve this rather cryptic error, one must put the
<code>alltt</code> inside a paragraph-style box. The following
modification of the above <em>does</em> work:
<blockquote>
@@ -57,13 +105,13 @@ The code above produces a box that&rsquo;s far too wide for the text. One
may want to use something that allows
<a href="FAQ-varwidth.html">variable size boxes</a> in place of the
<code>minipage</code> environment.
-<p>Oddly, although the <code>verbatim</code> environment wouldn&rsquo;t work
+<p/>Oddly, although the <code>verbatim</code> environment wouldn&rsquo;t work
inside a <code>\</code><code>fbox</code> command argument (see
<a href="FAQ-verbwithin.html">verbatim in command arguments</a>), you
get an error that complains about <code>\</code><code>item</code>: the environment&rsquo;s
internal list bites you before <code>verbatim</code> has even had a
chance to create its own sort of chaos.
-<p>Another (seemingly) obvious use of <code>\</code><code>fbox</code> also falls foul of this
+<p/>Another (seemingly) obvious use of <code>\</code><code>fbox</code> also falls foul of this
error:
<blockquote>
<pre>
@@ -75,5 +123,5 @@ either write your own macros to replace the insides of LaTeX&rsquo;s
sectioning macros, or look for some alternative in the packages
discussed in
&ldquo;<a href="FAQ-secthead.html">The style of section headings</a>&rdquo;.
-<p><p>This question on the Web: <a href="http://www.tex.ac.uk/cgi-bin/texfaq2html?label=errmissitem">http://www.tex.ac.uk/cgi-bin/texfaq2html?label=errmissitem</a>
+<p/><p>This question on the Web: <a href="http://www.tex.ac.uk/cgi-bin/texfaq2html?label=errmissitem">http://www.tex.ac.uk/cgi-bin/texfaq2html?label=errmissitem</a>
</body>