Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Spot
Spot
Commits
5b8ff7fb
Commit
5b8ff7fb
authored
Jan 13, 2004
by
Alexandre Duret-Lutz
Browse files
new upstream version
parent
90d139db
Changes
1
Hide whitespace changes
Inline
Side-by-side
lbtt/doc/texinfo.tex
View file @
5b8ff7fb
...
...
@@ -3,10 +3,11 @@
% Load plain if necessary, i.e., if running under initex.
\expandafter\ifx\csname
fmtname
\endcsname\relax\input
plain
\fi
%
\def\texinfoversion
{
200
3-12
-0
4
.1
7
}
\def\texinfoversion
{
200
4-01
-0
5
.1
6
}
%
% Copyright (C) 1985, 1986, 1988, 1990, 1991, 1992, 1993, 1994, 1995,
% 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
% 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004 Free Software
% Foundation, Inc.
%
% This texinfo.tex file is free software; you can redistribute it and/or
% modify it under the terms of the GNU General Public License as
...
...
@@ -102,6 +103,15 @@
% starts a new line in the output.
\newlinechar
= `
^^
J
% Use TeX 3.0's \inputlineno to get the line number, for better error
% messages, but if we're using an old version of TeX, don't do anything.
%
\ifx\inputlineno\thisisundefined
\let\linenumber
=
\empty
% Pre-3.0.
\else
\def\linenumber
{
l.
\the\inputlineno
:
\space
}
\fi
% Set up fixed words for English if not already set.
\ifx\putwordAppendix\undefined
\gdef\putwordAppendix
{
Appendix
}
\fi
\ifx\putwordChapter\undefined
\gdef\putwordChapter
{
Chapter
}
\fi
...
...
@@ -150,9 +160,12 @@
\chardef\exclamChar
= `
\!
\chardef\questChar
= `
\?
\chardef\semiChar
= `
\;
\chardef\spaceChar
= `
\
%
\chardef\underChar
= `
\_
\chardef\spaceChar
= `
\
%
\chardef\spacecat
= 10
\def\spaceisspace
{
\catcode\spaceChar
=
\spacecat
}
% Ignore a token.
%
\def\gobble
#1
{}
...
...
@@ -160,19 +173,6 @@
% The following is used inside several \edef's.
\def\makecsname
#1
{
\expandafter\noexpand\csname
#1
\endcsname
}
% Make an outer definition into an inner one (due to Chris Thompson).
% The arguments should be the control sequence to be defined, and the
% new of the \outer control sequence, as characters; the control
% sequence #1 is defined to be just the same as \csname#2\endcsname, but
% not \outer.
%
% For example, \innerdef\innernewcount{newcount} defines \innernewcount
% to be a non-outer version of \newcount.
%
\def\innerdef
#1#2
{
\edef
#1
{
\expandafter\noexpand\csname
#2
\endcsname
}}
%
%
\innerdef\innernewcount
{
newcount
}
%
% Hyphenation fixes.
\hyphenation
{
ap-pen-dix
}
\hyphenation
{
eshell
}
...
...
@@ -244,7 +244,7 @@
\tracingassigns
1
\fi
\tracingcommands
3
% 3 gives us more in etex
\errorcontextlines
\maxdimen
\errorcontextlines
16
}
%
% add check for \lastpenalty to plain's definitions. If the last thing
...
...
@@ -388,7 +388,7 @@
\def\next
{
#2
}
%
\begingroup
\obeylines
\
catcode
`
\
=10
\
spaceisspace
#1
%
\parseargline\empty
% Insert the \empty token, see \finishparsearg below.
}
...
...
@@ -402,21 +402,43 @@
% First remove any @comment, then any @c comment.
\def\argremovecomment
#1
\comment
#2
\ArgTerm
{
\argremovec
#1
\c\ArgTerm
}
\def\argremovec
#1
\c
#2
\ArgTerm
{
\argremovespace
#1
$
$
\ArgTerm
}
% \argremovec might leave us with trailing space, though; e.g.,
\def\argremovec
#1
\c
#2
\ArgTerm
{
\argcheckspaces
#1
\^
^
M
\ArgTerm
}
% Each occurence of `\^^M' or `<space>\^^M' is replaced by a single space.
%
% \argremovec might leave us with trailing space, e.g.,
% @end itemize @c foo
% Note that the argument cannot contain the TeX $, as its catcode is
% changed to \other when Texinfo source is read.
\def\argremovespace
#1
$
#
2
\ArgTerm
{
\finishparsearg
#
1
$
\ArgTerm
}
% This space token undergoes the same procedure and is eventually removed
% by \finishparsearg.
%
\def\argcheckspaces
#1
\^
^
M
{
\argcheckspacesX
#1
\^
^
M
\^
^
M
}
\def\argcheckspacesX
#1
\^
^
M
{
\argcheckspacesY
#1
\^
^
M
}
\def\argcheckspacesY
#1
\^
^
M#2
\^
^
M#3
\ArgTerm
{
%
\def\temp
{
#3
}
%
\ifx\temp\empty
% We cannot use \next here, as it holds the macro to run;
% thus we reuse \temp.
\let\temp\finishparsearg
\else
\let\temp\argcheckspaces
\fi
% Put the space token in:
\temp
#1 #3
\ArgTerm
}
% If a _delimited_ argument is enclosed in braces, they get stripped; so
% to get _exactly_ the rest of the line, we had to prevent such situation.
% We prepended an \empty token at the very beginning and we expand it
% We prepended an \empty token at the very beginning and we expand it
now,
% just before passing the control to \next.
% (But first, we have to spend the remaining $ or two.)
\def\finishparsearg
#1
$
#
2
\ArgTerm
{
\expandafter\next\expandafter
{
#
1
}}
% (Similarily, we have to think about #3 of \argcheckspacesY above: it is
% either the null string, or it ends with \^^M---thus there is no danger
% that a pair of braces would be stripped.
%
% But first, we have to remove the trailing space token.
%
\def\finishparsearg
#1
\ArgTerm
{
\expandafter\next\expandafter
{
#1
}}
% \
def
parsearg\foo{...}
% \parsearg
def
\foo{...}
% is roughly equivalent to
% \def\foo{\parsearg\Xfoo}
% \def\Xfoo#1{...}
...
...
@@ -424,10 +446,10 @@
% Actually, I use \csname\string\foo\endcsname, ie. \\foo, as it is my
% favourite TeX trick. --kasal, 16nov03
\def\
def
parsearg
#
1
{
%
\expandafter
\do
def
parsearg
\csname\string
#
1
\endcsname
#
1
%
\def\parsearg
def
#1
{
%
\expandafter
\doparsearg
def
\csname\string
#1
\endcsname
#1
%
}
\def\do
def
parsearg
#
1
#
2
{
%
\def\doparsearg
def
#1#2
{
%
\def
#2
{
\parsearg
#1
}
%
\def
#1##1
%
}
...
...
@@ -453,46 +475,66 @@
\def\flushcr
{
\ifx\par\lisppar
\def\next
##1
{}
\else
\let\next
=
\relax
\fi
\next
}
% Define the framework for environments in texinfo.tex. It's used like this:
%
% \envdef\foo{...}
% \def\Efoo{...}
%
% It's the responsibility of \envdef to insert \begingroup before the
% actual body; @end closes the group after calling \Efoo. \envdef also
% defines \thisenv, so the current environment is known; @end checks
% whether the environment name matches. The \checkenv macro can also be
% used to check whether the current environment is the one expected.
%
% Non-false conditionals (@iftex, @ifset) don't fit into this, so they
% are not treated as enviroments; they don't open a group. (The
% implementation of @end takes care not to call \endgroup in this
% special case.)
%% These are used to keep @begin/@end levels from running away
%% Call \inENV within environments (after a \begingroup)
\newif\ifENV
\ENVfalse
\def\inENV
{
\ifENV\relax\else\ENVtrue\fi
}
\def\ENVcheck
{
%
\ifENV\errmessage
{
Still within an environment; press RETURN to continue
}
\endgroup\fi
}
% This is not perfect, but it should reduce lossage
% @end foo executes the definition of \Efoo.
%
\defparsearg\end
{
%
\expandafter\ifx\csname
E#
1
\endcsname\relax
\badenderror
{
#
1
}
%
\else
% Everything's ok; the right environment has been started.
\csname
E#
1
\endcsname
\fi
}
% At runtime, environments start with this:
\def\startenvironment
#1
{
\begingroup\def\thisenv
{
#1
}}
% initialize
\let\thisenv\empty
\def\badenderror
#
1
{
%
\expandafter\ifx\csname
#
1
\endcsname\relax
% There's no \foo, i.e., no ``environment'' foo.
\errhelp
=
\EMsimple
\errmessage
{
Undefined command `@end #
1
'
}
%
% ... but they get defined via ``\envdef\foo{...}'':
\long\def\envdef
#1#2
{
\def
#1
{
\startenvironment
#1#2
}}
\def\envparseargdef
#1#2
{
\parseargdef
#1
{
\startenvironment
#1#2
}}
% Check whether we're in the right environment:
\def\checkenv
#1
{
%
\def\temp
{
#1
}
%
\ifx\thisenv\temp
\else
\
unmatche
den
d
err
or
{
#
1
}
%
\
ba
den
v
err
\fi
}
% There is an environment #1, but it hasn't been started. Give an error.
%
\def\unmatchedenderror
#
1
{
%
% Evironment mismatch, #1 expected:
\def\badenverr
{
%
\errhelp
=
\EMsimple
\errmessage
{
This `@end #
1
' doesn't have a matching `@#
1
'
}
%
\errmessage
{
This command can appear only
\inenvironment\temp
,
not
\inenvironment\thisenv
}
%
}
\def\inenvironment
#1
{
%
\ifx
#1
\empty
out of any environment
%
\else
in environment
\expandafter\string
#1
%
\fi
}
% Define the control sequence \E#1 to give an unmatched @end error.
% @end foo executes the definition of \Efoo.
% But first, it executes a specialized version of \checkenv
%
\def\defineunmatchedend
#
1
{
%
\expandafter\def\csname
E#
1
\endcsname
{
\unmatchedenderror
{
#
1
}}
%
\parseargdef\end
{
%
\if
1
\csname
iscond.#1
\endcsname
\else
% The general wording of \badenverr may not be ideal, but... --kasal, 06nov03
\expandafter\checkenv\csname
#1
\endcsname
\csname
E#1
\endcsname
\endgroup
\fi
}
\newhelp\EMsimple
{
Press RETURN to continue.
}
...
...
@@ -528,6 +570,9 @@
!gdef!rbraceatcmd[@
}
]
%
!endgroup
% @comma{} to avoid , parsing problems.
\let\comma
= ,
% Accents: @, @dotaccent @ringaccent @ubaraccent @udotaccent
% Others are defined by plain TeX: @` @' @" @^ @~ @= @u @v @H.
\let\,
=
\c
...
...
@@ -537,10 +582,12 @@
\let\ubaraccent
=
\b
\let\udotaccent
=
\d
% Other special characters: @questiondown @exclamdown
% Other special characters: @questiondown @exclamdown
@ordf @ordm
% Plain TeX defines: @AA @AE @O @OE @L (plus lowercase versions) @ss.
\def\questiondown
{
?`
}
\def\exclamdown
{
!`
}
\def\ordf
{
\leavevmode\raise
1ex
\hbox
{
\selectfonts\lllsize
\underbar
{
a
}}}
\def\ordm
{
\leavevmode\raise
1ex
\hbox
{
\selectfonts\lllsize
\underbar
{
o
}}}
% Dotless i and dotless j, used for accents.
\def\imacro
{
i
}
...
...
@@ -553,6 +600,25 @@
\fi\fi
}
% The \TeX{} logo, as in plain, but resetting the spacing so that a
% period following counts as ending a sentence. (Idea found in latex.)
%
\def\TeX
{
T
\kern
-.1667em
\lower
.5ex
\hbox
{
E
}
\kern
-.125emX
\spacefactor
=3000
}
% @LaTeX{} logo. Not quite the same results as the definition in
% latex.ltx, since we use a different font for the raised A; it's most
% convenient for us to use an explicitly smaller font, rather than using
% the \scriptstyle font (since we don't reset \scriptstyle and
% \scriptscriptstyle).
%
\def\LaTeX
{
%
L
\kern
-.36em
{
\setbox
0=
\hbox
{
T
}
%
\vbox
to
\ht
0
{
\hbox
{
\selectfonts\lllsize
A
}
\vss
}}
%
\kern
-.15em
\TeX
}
% Be sure we're in horizontal mode when doing a tie, since we make space
% equivalent to this in @example-like environments. Otherwise, a space
% at the beginning of a line will start with \penalty -- and
...
...
@@ -606,61 +672,14 @@
\newbox\groupbox
\def\vfilllimit
{
0.7
}
%
\def\group
{
\begingroup
\
env
def\group
{
%
\ifnum\catcode
`
\^
^
M=
\active
\else
\errhelp
=
\groupinvalidhelp
\errmessage
{
@group invalid in context where filling is enabled
}
%
\fi
\startsavinginserts
%
% The \vtop we start below produces a box with normal height and large
% depth; thus, TeX puts \baselineskip glue before it, and (when the
% next line of text is done) \lineskip glue after it. (See p.82 of
% the TeXbook.) Thus, space below is not quite equal to space
% above. But it's pretty close.
\def\Egroup
{
%
\egroup
% End the \vtop.
% \dimen0 is the vertical size of the group's box.
\dimen
0
=
\ht\groupbox
\advance\dimen
0
by
\dp\groupbox
% \dimen2 is how much space is left on the page (more or less).
\dimen
2
=
\pageheight
\advance\dimen
2
by
-
\pagetotal
% if the group doesn't fit on the current page, and it's a big big
% group, force a page break.
\ifdim
\dimen
0
>
\dimen
2
\ifdim
\pagetotal
<
\vfilllimit\pageheight
\page
\fi
\fi
\box\groupbox
\checkinserts
\endgroup
% End the \group.
}
%
%
\setbox\groupbox
=
\vtop\bgroup
% We have to put a strut on the last line in case the @group is in
% the midst of an example, rather than completely enclosing it.
% Otherwise, the interline space between the last line of the group
% and the first line afterwards is too small. But we can't put the
% strut in \Egroup, since there it would be on a line by itself.
% Hence this just inserts a strut at the beginning of each line.
\everypar
=
{
\strut
}
%
%
% Since we have a strut on every line, we don't need any of TeX's
% normal interline spacing.
\offinterlineskip
%
% OK, but now we have to do something about blank
% lines in the input in @example-like environments, which normally
% just turn into \lisppar, which will insert no space now that we've
% turned off the interline space. Simplest is to make them be an
% empty paragraph.
\ifx\par\lisppar
\edef\par
{
\leavevmode
\par
}
%
%
% Reset ^^M's definition to new definition of \par.
\obeylines
\fi
%
% Do @comment since we are called inside an environment such as
% @example, where each end-of-line in the input causes an
% end-of-line in the output. We don't want the end-of-line after
...
...
@@ -670,6 +689,32 @@
\comment
}
%
% The \vtop produces a box with normal height and large depth; thus, TeX puts
% \baselineskip glue before it, and (when the next line of text is done)
% \lineskip glue after it. Thus, space below is not quite equal to space
% above. But it's pretty close.
\def\Egroup
{
%
% To get correct interline space between the last line of the group
% and the first line afterwards, we have to propagate \prevdepth.
\endgraf
% Not \par, as it may have been set to \lisppar.
\global\dimen
1 =
\prevdepth
\egroup
% End the \vtop.
% \dimen0 is the vertical size of the group's box.
\dimen
0 =
\ht\groupbox
\advance\dimen
0 by
\dp\groupbox
% \dimen2 is how much space is left on the page (more or less).
\dimen
2 =
\pageheight
\advance\dimen
2 by -
\pagetotal
% if the group doesn't fit on the current page, and it's a big big
% group, force a page break.
\ifdim
\dimen
0 >
\dimen
2
\ifdim
\pagetotal
<
\vfilllimit\pageheight
\page
\fi
\fi
\box\groupbox
\prevdepth
=
\dimen
1
\checkinserts
}
%
% TeX puts in an \escapechar (i.e., `@') at the beginning of the help
% message, so this ends up printing `@group can only ...'.
%
...
...
@@ -683,7 +728,7 @@ where each line of input produces a line of output.}
\newdimen\mil
\mil
=0.001in
% Old definition--didn't work.
%\
def
parsearg\need{\par %
%\parsearg
def
\need{\par %
%% This method tries to make TeX break the page naturally
%% if the depth of the box does not fit.
%{\baselineskip=0pt%
...
...
@@ -691,7 +736,7 @@ where each line of input produces a line of output.}
%\prevdepth=-1000pt
%}}
\
def
parsearg\need
{
%
\parsearg
def
\need
{
%
% Ensure vertical mode, so we don't make a big box in the middle of a
% paragraph.
\par
...
...
@@ -730,35 +775,10 @@ where each line of input produces a line of output.}
\fi
}
% @br forces paragraph break
% @br forces paragraph break
(and is undocumented).
\let\br
=
\par
% @dots{} output an ellipsis using the current font.
% We do .5em per period so that it has the same spacing in a typewriter
% font as three actual period characters.
%
\def\dots
{
%
\leavevmode
\hbox
to
1
.
5
em
{
%
\hskip
0
pt plus
0
.
25
fil minus
0
.
25
fil
.
\hss
.
\hss
.
%
\hskip
0
pt plus
0
.
5
fil minus
0
.
5
fil
}
%
}
% @enddots{} is an end-of-sentence ellipsis.
%
\def\enddots
{
%
\leavevmode
\hbox
to
2
em
{
%
\hskip
0
pt plus
0
.
25
fil minus
0
.
25
fil
.
\hss
.
\hss
.
\hss
.
%
\hskip
0
pt plus
0
.
5
fil minus
0
.
5
fil
}
%
\spacefactor
=
3000
}
% @page forces the start of a new page.
%
\def\page
{
\par\vfill\supereject
}
...
...
@@ -771,10 +791,10 @@ where each line of input produces a line of output.}
\newskip\exdentamount
% This defn is used inside fill environments such as @defun.
\
def
parsearg\exdent
{
\hfil\break\hbox
{
\kern
-
\exdentamount
{
\rm
#
1
}}
\hfil\break
}
\parsearg
def
\exdent
{
\hfil\break\hbox
{
\kern
-
\exdentamount
{
\rm
#1
}}
\hfil\break
}
% This defn is used inside nofill environments such as @example.
\
def
parsearg\nofillexdent
{{
\advance
\leftskip
by
-
\exdentamount
\parsearg
def
\nofillexdent
{{
\advance
\leftskip
by -
\exdentamount
\leftline
{
\hskip\leftskip
{
\rm
#1
}}}}
% @inmargin{WHICH}{TEXT} puts TEXT in the WHICH margin next to the current
...
...
@@ -870,19 +890,28 @@ where each line of input produces a line of output.}
% @center line
% outputs that line, centered.
%
\defparsearg\center
{
%
\ifhmode
\hfil\break
\fi
\parseargdef\center
{
%
\ifhmode
\let\next\centerH
\else
\let\next\centerV
\fi
\next
{
\hfil
\ignorespaces
#1
\unskip
\hfil
}
%
}
\def\centerH
#1
{
%
{
%
\hfil\break
\advance\hsize
by -
\leftskip
\advance\hsize
by -
\rightskip
\line
{
\hfil
\ignorespaces
#
1
\unskip
\hfil
}
%
\line
{
#1
}
%
\break
}
%
\ifhmode
\break
\fi
}
\def\centerV
#1
{
\line
{
\kern\leftskip
#1
\kern\rightskip
}}
% @sp n outputs n lines of vertical space
\
def
parsearg\sp
{
\vskip
#
1
\baselineskip
}
\parsearg
def
\sp
{
\vskip
#1
\baselineskip
}
% @comment ...line which is ignored...
% @c is the same as @comment
...
...
@@ -903,7 +932,7 @@ where each line of input produces a line of output.}
\def\asisword
{
asis
}
% no translation, these are keywords
\def\noneword
{
none
}
%
\
def
parsearg\paragraphindent
{
%
\parsearg
def
\paragraphindent
{
%
\def\temp
{
#1
}
%
\ifx\temp\asisword
\else
...
...
@@ -920,7 +949,7 @@ where each line of input produces a line of output.}
% We'll use ems for NCHARS like @paragraphindent.
% It seems @exampleindent asis isn't necessary, but
% I preserve it to make it similar to @paragraphindent.
\
def
parsearg\exampleindent
{
%
\parsearg
def
\exampleindent
{
%
\def\temp
{
#1
}
%
\ifx\temp\asisword
\else
...
...
@@ -947,7 +976,7 @@ where each line of input produces a line of output.}
%
\def\insertword
{
insert
}
%
\
def
parsearg\firstparagraphindent
{
%
\parsearg
def
\firstparagraphindent
{
%
\def\temp
{
#1
}
%
\ifx\temp\noneword
\let\suppressfirstparagraphindent
=
\dosuppressfirstparagraphindent
...
...
@@ -1019,7 +1048,7 @@ where each line of input produces a line of output.}
\mathactive
$
\finishmath
}
\def\finishmath
#1
{
#1
$
\
E
tex
}
\def\finishmath
#
1
{
#
1
$
\
endgroup
}
% Close the group opened by \
tex
.
% Some active characters (such as <) are spaced differently in math.
% We have to reset their definitions in case the @math was an argument
...
...
@@ -1042,6 +1071,31 @@ where each line of input produces a line of output.}
\def\bullet
{$
\ptexbullet
$}
\def\minus
{$
-
$}
% @dots{} outputs an ellipsis using the current font.
% We do .5em per period so that it has the same spacing in a typewriter
% font as three actual period characters.
%
\def\dots
{
%
\leavevmode
\hbox
to 1.5em
{
%
\hskip
0pt plus 0.25fil
.
\hfil
.
\hfil
.
%
\hskip
0pt plus 0.5fil
}
%
}
% @enddots{} is an end-of-sentence ellipsis.
%
\def\enddots
{
%
\dots
\spacefactor
=3000
}
% @comma{} is so commas can be inserted into text without messing up
% Texinfo's parsing.
%
\let\comma
= ,
% @refill is a no-op.
\let\refill
=
\relax
...
...
@@ -1057,7 +1111,9 @@ where each line of input produces a line of output.}
% This makes it possible to make a .fmt file for texinfo.
\def\setfilename
{
%
\iflinks
\readauxfile
\tryauxfile
% Open the new aux file. TeX will close it automatically at exit.
\immediate\openout\auxfile
=
\jobname
.aux
\fi
% \openindices needs to do some work in any case.
\openindices
\fixbackslash
% Turn off hack to swallow `\input texinfo'.
...
...
@@ -1065,11 +1121,9 @@ where each line of input produces a line of output.}
%
% If texinfo.cnf is present on the system, read it.
% Useful for site-wide @afourpaper, etc.
% Just to be on the safe side, close the input stream before the \input.
\openin
1 texinfo.cnf
\ifeof
1
\let\temp
=
\relax
\else
\def\temp
{
\input
texinfo.cnf
}
\fi
\closein
1
\temp
\ifeof
1
\else
\input
texinfo.cnf
\fi
\closein
1
%
\comment
% Ignore the actual filename.
}
...
...
@@ -1172,22 +1226,32 @@ where each line of input produces a line of output.}
}
%
\def\pdfmakeoutlines
{
%
\openin
1
\jobname
.toc
\ifeof
1
\else\begingroup
\closein
1
\begingroup
% Thanh's hack / proper braces in bookmarks
\edef\mylbrace
{
\iftrue
\string
{
\else
}
\fi
}
\let\{
=
\mylbrace
\edef\myrbrace
{
\iffalse
{
\else\string
}
\fi
}
\let\}
=
\myrbrace
%
% Read toc silently, to get counts of subentries for \pdfoutline.
\def\numchapentry
##
1
##
2
##
3
##
4
{
\def\thischapnum
{
##
2
}}
%
\def\numchapentry
##1##2##3##4
{
%
\def\thischapnum
{
##2
}
%
\let\thissecnum\empty
\let\thissubsecnum\empty
}
%
\def\numsecentry
##1##2##3##4
{
%
\def\thissecnum
{
##
2
}
%
\advancenumber
{
chap
\thischapnum
}}
%
\advancenumber
{
chap
\thischapnum
}
%
\def\thissecnum
{
##2
}
%
\let\thissubsecnum\empty
}
%
\def\numsubsecentry
##1##2##3##4
{
%
\def\thissubsecnum
{
##
2
}
%
\advancenumber
{
sec
\thissecnum
}}
%
\def\numsubsubsecentry
##
1
##
2
##
3
##
4
{
\advancenumber
{
subsec
\thissubsecnum
}}
%
\advancenumber
{
sec
\thissecnum
}
%
\def\thissubsecnum
{
##2
}
%
}
%
\def\numsubsubsecentry
##1##2##3##4
{
%
\advancenumber
{
subsec
\thissubsecnum
}
%
}
%
\let\thischapnum\empty
\let\thissecnum\empty
\let\thissubsecnum\empty
%
% use \def rather than \let here because we redefine \chapentry et
% al. a second time, below.
...
...
@@ -1219,7 +1283,7 @@ where each line of input produces a line of output.}
\indexnofonts
\turnoffactive
\input
\jobname
.toc
\endgroup
\fi
\endgroup
}
%
\def\makelinks
#1,
{
%
...
...
@@ -1305,16 +1369,34 @@ where each line of input produces a line of output.}
\message
{
fonts,
}
% Font-change commands.
% Change the current font style to #1, remembering it in \curfontstyle.
% For now, we do not accumulate font styles: @b{@i{foo}} prints foo in
% italics, not bold italics.
%
\def\setfontstyle
#1
{
%
\def\curfontstyle
{
#1
}
% not as a control sequence, because we are \edef'd.
\csname
ten#1
\endcsname
% change the current font
}
% Select #1 fonts with the current style.
%
\def\selectfonts
#1
{
\csname
#1fonts
\endcsname
\csname\curfontstyle\endcsname
}
\def\rm
{
\fam
=0
\setfontstyle
{
rm
}}
\def\it
{
\fam
=
\itfam
\setfontstyle
{
it
}}
\def\sl
{
\fam
=
\slfam
\setfontstyle
{
sl
}}
\def\bf
{
\fam
=
\bffam
\setfontstyle
{
bf
}}
\def\tt
{
\fam
=
\ttfam
\setfontstyle
{
tt
}}