summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/generic/FAQ-en/html/FAQ-spinmacro.html
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/doc/generic/FAQ-en/html/FAQ-spinmacro.html')
-rw-r--r--Master/texmf-dist/doc/generic/FAQ-en/html/FAQ-spinmacro.html36
1 files changed, 18 insertions, 18 deletions
diff --git a/Master/texmf-dist/doc/generic/FAQ-en/html/FAQ-spinmacro.html b/Master/texmf-dist/doc/generic/FAQ-en/html/FAQ-spinmacro.html
index 9dc949a38a4..56cf213ae15 100644
--- a/Master/texmf-dist/doc/generic/FAQ-en/html/FAQ-spinmacro.html
+++ b/Master/texmf-dist/doc/generic/FAQ-en/html/FAQ-spinmacro.html
@@ -2,29 +2,29 @@
<title>UK TeX FAQ -- question label spinmacro</title>
</head><body>
<h3>Spaces in macros</h3>
-<p/>It&rsquo;s very easy to write macros that produce space in the typeset
-output where it&rsquo;s neither desired nor expected. Spaces introduced by
-macros are particularly insidious because they don&rsquo;t amalgamate with
+<p/>It&#8217;s very easy to write macros that produce space in the typeset
+output where it&#8217;s neither desired nor expected. Spaces introduced by
+macros are particularly insidious because they don&#8217;t amalgamate with
spaces around the macro (unlike consecutive spaces that you
type), so your output can have a single bloated space that proves
-to be made up of two or even more spaces that haven&rsquo;t amalgamated.
+to be made up of two or even more spaces that haven&#8217;t amalgamated.
And of course, your output can also have a space where none was wanted
at all.
<p/>Spaces are produced, inside a macro as elsewhere, by space or tab
characters, or by end-of-line characters. There are two basic rules
to remember when writing a macro: first, the rules for ignoring spaces
-when you&rsquo;re typing macros are just the same as the rules that apply
-when you&rsquo;re typing ordinary text, and second, rules for ignoring
+when you&#8217;re typing macros are just the same as the rules that apply
+when you&#8217;re typing ordinary text, and second, rules for ignoring
spaces do <em>not</em> apply to spaces produced while a macro is being
-obeyed (&ldquo;expanded&rdquo;).
+obeyed (&#8220;expanded&#8221;).
<p/>Spaces are ignored in vertical mode (between paragraphs), at the
beginning of a line, and after a command name. Since sequences of
-spaces are collapsed into one, it &lsquo;feels as if&rsquo; spaces are ignored if
+spaces are collapsed into one, it &#8216;feels as if&#8217; spaces are ignored if
they follow another space. Space can have syntactic meaning after
certain sorts of non-braced arguments (e.g., <em>count</em> and
<em>dimen</em> variable assignments in Plain TeX) and after certain
control words (e.g., in <code>\</code><code>hbox</code> <code>to</code>, so again we have instances
-where it &lsquo;feels as if&rsquo; spaces are being ignored when they&rsquo;re merely
+where it &#8216;feels as if&#8217; spaces are being ignored when they&#8217;re merely
working quietly for their living.
<p/>Consider the following macro, fairly faithfully adapted from one that
appeared on <i>comp.text.tex</i>:
@@ -37,8 +37,8 @@ appeared on <i>comp.text.tex</i>:
The macro definition contains five spaces:
<ul>
<li> after the opening <code>{</code> of the macro body; this space will be
- ignored, not because &ldquo;because the macro appears at the start of a
- line&rdquo;, but rather because the macro was designed to operate between
+ ignored, not because &#8220;because the macro appears at the start of a
+ line&#8221;, but rather because the macro was designed to operate between
paragraphs
<li> after <code>\</code><code>bigskip</code>; this space will be ignored (while the macro
is being defined) because it follows a command name
@@ -53,7 +53,7 @@ The macro definition contains five spaces:
</ul>
The original author of the macro had been concerned that the starts of
his lines with this macro in them were not at the left margin, and
-that the text appearing after the macro wasn&rsquo;t always properly
+that the text appearing after the macro wasn&#8217;t always properly
aligned. These problems arose from the space at the start of the
mandatory argument of <code>\</code><code>makebox</code> and the space immediately after the
same argument. He had written his macro in that way to emphasise the
@@ -80,27 +80,27 @@ emphasising the structure):
</blockquote><p>
Care has been taken to ensure that every space in the revised
definition is ignored, so none appears in the output. The revised
-definition takes the &ldquo;belt and braces&rdquo; approach, explicitly dealing
+definition takes the &#8220;belt and braces&#8221; approach, explicitly dealing
with every line ending (although, as noted above, a space introduced
at the end of the first line of the macro would have been ignored in
-actual use of the macro. This is the best technique, in fact &mdash; it&rsquo;s
+actual use of the macro. This is the best technique, in fact &#8212; it&#8217;s
easier to blindly suppress spaces than to analyse at every point
whether you actually need to. Three techniques were used to suppress
spaces:
<ul>
<li> placing a <code>%</code> character at the end of a line
(as in the 1st, 3rd and 5th lines),
-<li> ending a line &lsquo;naturally&rsquo; with a control sequence, as in line 2,
+<li> ending a line &#8216;naturally&#8217; with a control sequence, as in line 2,
and
-<li> ending a line with an &lsquo;artificial&rsquo; control sequence, as in line
+<li> ending a line with an &#8216;artificial&#8217; control sequence, as in line
4; the control sequence in this case (<code>\</code><code>relax</code>) is a no-op in many
- circumstances (as here), but this usage is deprecated &mdash; a
+ circumstances (as here), but this usage is deprecated &#8212; a
<code>%</code> character would have been better.
</ul>
Beware of the (common) temptation to place a space <em>before</em> a
<code>%</code> character: if you do this you might as well omit
the <code>%</code> altogether.
-<p/>In &ldquo;real life&rdquo;, of course, the spaces that appear in macros are far
+<p/>In &#8220;real life&#8221;, of course, the spaces that appear in macros are far
more cryptic than those in the example above. The most common spaces
arise from unprotected line ends, and this is an error that
occasionally appears even in macros written by the most accomplished