<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>change log for rtems (2011-12-12)</title>
</head>
<body text='#000000' bgcolor='#ffffff'>
<a name='cs1'></a>
<table border='0' cellspacing='0' cellpadding='5' width='100%' bgcolor='#eeeeee'>
<tr><td colspan='3' bgcolor='#dddddd'>
<font color='#bb2222'><strong>ralf</strong></font>
</td></tr>
<tr><td colspan='3' bgcolor='#dddddd'><pre>2011-12-13 Ralf Corsépius <ralf.corsepius@rtems.org>
* compile, depcomp, mdate-sh, texinfo.tex:
Update from automake-1.11.1b.
</pre></td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/ChangeLog.diff?r1=text&tr1=1.409&r2=text&tr2=1.410&diff_format=h">M</a></td><td width='1%'>1.410</td><td width='100%'>ChangeLog</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/compile.diff?r1=text&tr1=1.1&r2=text&tr2=1.2&diff_format=h">M</a></td><td width='1%'>1.2</td><td width='100%'>compile</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/depcomp.diff?r1=text&tr1=1.1&r2=text&tr2=1.2&diff_format=h">M</a></td><td width='1%'>1.2</td><td width='100%'>depcomp</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/mdate-sh.diff?r1=text&tr1=1.1&r2=text&tr2=1.2&diff_format=h">M</a></td><td width='1%'>1.2</td><td width='100%'>mdate-sh</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/texinfo.tex.diff?r1=text&tr1=1.1&r2=text&tr2=1.2&diff_format=h">M</a></td><td width='1%'>1.2</td><td width='100%'>texinfo.tex</td></tr>
</table>
<pre>
<font color='#006600'>diff -u rtems/ChangeLog:1.409 rtems/ChangeLog:1.410
--- rtems/ChangeLog:1.409 Wed Nov 9 08:20:22 2011
+++ rtems/ChangeLog Mon Dec 12 22:59:22 2011
</font><font color='#997700'>@@ -1,3 +1,8 @@
</font><font color='#000088'>+2011-12-13 Ralf Corsépius <ralf.corsepius@rtems.org>
+
+ * compile, depcomp, mdate-sh, texinfo.tex:<span style="background-color: #FF0000"> </span>
+ Update from automake-1.11.1b.
+
</font> 2011-11-09 Joel Sherrill <joel.sherrill@oarcorp.com>
* MAINTAINERS: Rewrite and update.
<font color='#006600'>diff -u rtems/compile:1.1 rtems/compile:1.2
--- rtems/compile:1.1 Mon Oct 3 04:38:27 2011
+++ rtems/compile Mon Dec 12 22:59:22 2011
</font><font color='#997700'>@@ -1,9 +1,9 @@
</font> #! /bin/sh
# Wrapper for compilers which do not understand `-c -o'.
<font color='#880000'>-scriptversion=2009-10-06.20; # UTC
</font><font color='#000088'>+scriptversion=2010-11-15.09; # UTC
</font>
<font color='#880000'>-# Copyright (C) 1999, 2000, 2003, 2004, 2005, 2009 Free Software
</font><font color='#000088'>+# Copyright (C) 1999, 2000, 2003, 2004, 2005, 2009, 2010 Free Software
</font> # Foundation, Inc.
# Written by Tom Tromey <tromey@cygnus.com>.
#
<font color='#997700'>@@ -29,6 +29,171 @@
</font> # bugs to <bug-automake@gnu.org> or send patches to
# <automake-patches@gnu.org>.
<font color='#000088'>+nl='
+'
+
+# We need space, tab and new line, in precisely that order. Quoting is
+# there to prevent tools from complaining about whitespace usage.
+IFS=" "" $nl"
+
+file_conv=
+
+# func_file_conv build_file lazy
+# Convert a $build file to $host form and store it in $file
+# Currently only supports Win32 hosts. If the determined conversion
+# type is listed in (the comma separated) LAZY, no conversion will
+# take place.
+func_file_conv ()
+{
+ file=$1
+ case $file in
+ / | /[!/]*) # absolute file, and not a UNC file
+ if test -z "$file_conv"; then
+ # lazily determine how to convert abs files
+ case `uname -s` in
+ MINGW*)
+ file_conv=mingw
+ ;;
+ CYGWIN*)
+ file_conv=cygwin
+ ;;
+ *)
+ file_conv=wine
+ ;;
+ esac
+ fi
+ case $file_conv/,$2, in
+ *,$file_conv,*)
+ ;;
+ mingw/*)
+ file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'`
+ ;;
+ cygwin/*)
+ file=`cygpath -m "$file" || echo "$file"`
+ ;;
+ wine/*)
+ file=`winepath -w "$file" || echo "$file"`
+ ;;
+ esac
+ ;;
+ esac
+}
+
+# func_cl_wrapper cl arg...
+# Adjust compile command to suit cl
+func_cl_wrapper ()
+{
+ # Assume a capable shell
+ lib_path=
+ shared=:
+ linker_opts=
+ for arg
+ do
+ if test -n "$eat"; then
+ eat=
+ else
+ case $1 in
+ -o)
+ # configure might choose to run compile as `compile cc -o foo foo.c'.
+ eat=1
+ case $2 in
+ *.o | *.[oO][bB][jJ])
+ func_file_conv "$2"
+ set x "$@" -Fo"$file"
+ shift
+ ;;
+ *)
+ func_file_conv "$2"
+ set x "$@" -Fe"$file"
+ shift
+ ;;
+ esac
+ ;;
+ -I*)
+ func_file_conv "${1#-I}" mingw
+ set x "$@" -I"$file"
+ shift
+ ;;
+ -l*)
+ lib=${1#-l}
+ found=no
+ save_IFS=$IFS
+ IFS=';'
+ for dir in $lib_path $LIB
+ do
+ IFS=$save_IFS
+ if $shared && test -f "$dir/$lib.dll.lib"; then
+ found=yes
+ set x "$@" "$dir/$lib.dll.lib"
+ break
+ fi
+ if test -f "$dir/$lib.lib"; then
+ found=yes
+ set x "$@" "$dir/$lib.lib"
+ break
+ fi
+ done
+ IFS=$save_IFS
+
+ test "$found" != yes && set x "$@" "$lib.lib"
+ shift
+ ;;
+ -L*)
+ func_file_conv "${1#-L}"
+ if test -z "$lib_path"; then
+ lib_path=$file
+ else
+ lib_path="$lib_path;$file"
+ fi
+ linker_opts="$linker_opts -LIBPATH:$file"
+ ;;
+ -static)
+ shared=false
+ ;;
+ -Wl,*)
+ arg=${1#-Wl,}
+ save_ifs="$IFS"; IFS=','
+ for flag in $arg; do
+ IFS="$save_ifs"
+ linker_opts="$linker_opts $flag"
+ done
+ IFS="$save_ifs"
+ ;;
+ -Xlinker)
+ eat=1
+ linker_opts="$linker_opts $2"
+ ;;
+ -*)
+ set x "$@" "$1"
+ shift
+ ;;
+ *.cc | *.CC | *.cxx | *.CXX | *.[cC]++)
+ func_file_conv "$1"
+ set x "$@" -Tp"$file"
+ shift
+ ;;
+ *.c | *.cpp | *.CPP | *.lib | *.LIB | *.Lib | *.OBJ | *.obj | *.[oO])
+ func_file_conv "$1" mingw
+ set x "$@" "$file"
+ shift
+ ;;
+ *)
+ set x "$@" "$1"
+ shift
+ ;;
+ esac
+ fi
+ shift
+ done
+ if test -n "$linker_opts"; then
+ linker_opts="-link$linker_opts"
+ fi
+ exec "$@" $linker_opts
+ exit 1
+}
+
+eat=
+
</font> case $1 in
'')
echo "$0: No command. Try \`$0 --help' for more information." 1>&2
<font color='#997700'>@@ -53,11 +218,13 @@
</font> echo "compile $scriptversion"
exit $?
;;
<font color='#000088'>+ cl | *[/\\]cl | cl.exe | *[/\\]cl.exe )
+ func_cl_wrapper "$@" # Doesn't return...
+ ;;
</font> esac
ofile=
cfile=
<font color='#880000'>-eat=
</font>
for arg
do
<font color='#006600'>diff -u rtems/depcomp:1.1 rtems/depcomp:1.2
--- rtems/depcomp:1.1 Mon Oct 3 04:38:27 2011
+++ rtems/depcomp Mon Dec 12 22:59:22 2011
</font><font color='#997700'>@@ -1,10 +1,10 @@
</font> #! /bin/sh
# depcomp - compile a program generating dependencies as side-effects
<font color='#880000'>-scriptversion=2009-04-28.21; # UTC
</font><font color='#000088'>+scriptversion=2011-12-04.11; # UTC
</font>
<font color='#880000'>-# Copyright (C) 1999, 2000, 2003, 2004, 2005, 2006, 2007, 2009 Free
-# Software Foundation, Inc.
</font><font color='#000088'>+# Copyright (C) 1999, 2000, 2003, 2004, 2005, 2006, 2007, 2009, 2010,
+# 2011 Free Software Foundation, Inc.
</font>
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
<font color='#997700'>@@ -44,7 +44,7 @@
</font> object Object file output by `PROGRAMS ARGS'.
DEPDIR directory where to store dependencies.
depfile Dependency file to output.
<font color='#880000'>- tmpdepfile Temporary file to use when outputing dependencies.
</font><font color='#000088'>+ tmpdepfile Temporary file to use when outputting dependencies.
</font> libtool Whether libtool is used (yes/no).
Report bugs to <bug-automake@gnu.org>.
<font color='#997700'>@@ -90,10 +90,18 @@
</font> # This is just like msvisualcpp but w/o cygpath translation.
# Just convert the backslash-escaped backslashes to single forward
# slashes to satisfy depend.m4
<font color='#880000'>- cygpath_u="sed s,\\\\\\\\,/,g"
</font><font color='#000088'>+ cygpath_u='sed s,\\\\,/,g'
</font> depmode=msvisualcpp
fi
<font color='#000088'>+if test "$depmode" = msvc7msys; then
+ # This is just like msvc7 but w/o cygpath translation.
+ # Just convert the backslash-escaped backslashes to single forward
+ # slashes to satisfy depend.m4
+ cygpath_u='sed s,\\\\,/,g'
+ depmode=msvc7
+fi
+
</font> case "$depmode" in
gcc3)
## gcc 3 implements dependency tracking that does exactly what
<font color='#997700'>@@ -158,10 +166,12 @@
</font> ' < "$tmpdepfile" |
## Some versions of gcc put a space before the `:'. On the theory
## that the space means something, we add a space to the output as
<font color='#880000'>-## well.
</font><font color='#000088'>+## well. hp depmode also adds that space, but also prefixes the VPATH
+## to the object. Take care to not repeat it in the output.
</font> ## Some versions of the HPUX 10.20 sed can't process this invocation
## correctly. Breaking it into two sed invocations is a workaround.
<font color='#880000'>- sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
</font><font color='#000088'>+ sed -e 's/^\\$//' -e '/^$/d' -e "s|.*$object$||" -e '/:$/d' \
+ | sed -e 's/$/ :/' >> "$depfile"
</font> rm -f "$tmpdepfile"
;;
<font color='#997700'>@@ -405,6 +415,52 @@
</font> rm -f "$tmpdepfile"
;;
<font color='#000088'>+msvc7)
+ if test "$libtool" = yes; then
+ showIncludes=-Wc,-showIncludes
+ else
+ showIncludes=-showIncludes
+ fi
+ "$@" $showIncludes > "$tmpdepfile"
+ stat=$?
+ grep -v '^Note: including file: ' "$tmpdepfile"
+ if test "$stat" = 0; then :
+ else
+ rm -f "$tmpdepfile"
+ exit $stat
+ fi
+ rm -f "$depfile"
+ echo "$object : \\" > "$depfile"
+ # The first sed program below extracts the file names and escapes
+ # backslashes for cygpath. The second sed program outputs the file
+ # name when reading, but also accumulates all include files in the
+ # hold buffer in order to output them again at the end. This only
+ # works with sed implementations that can handle large buffers.
+ sed < "$tmpdepfile" -n '
+/^Note: including file: *\(.*\)/ {
+ s//\1/
+ s/\\/\\\\/g
+ p
+}' | $cygpath_u | sort -u | sed -n '
+s/ /\\ /g
+s/\(.*\)/ \1 \\/p
+s/.\(.*\) \\/\1:/
+H
+$ {
+ s/.*/ /
+ G
+ p
+}' >> "$depfile"
+ rm -f "$tmpdepfile"
+ ;;
+
+msvc7msys)
+ # This case exists only to let depend.m4 do its work. It works by
+ # looking at the text of this script. This case will never be run,
+ # since it is checked for above.
+ exit 1
+ ;;
+
</font> #nosideeffect)
# This comment above is used by automake to tell side-effect
# dependency tracking mechanisms from slower ones.
<font color='#997700'>@@ -503,7 +559,9 @@
</font> touch "$tmpdepfile"
${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@"
rm -f "$depfile"
<font color='#880000'>- cat < "$tmpdepfile" > "$depfile"
</font><font color='#000088'>+ # makedepend may prepend the VPATH from the source file name to the object.
+ # No need to regex-escape $object, excess matching of '.' is harmless.
+ sed "s|^.*\($object *:\)|\1|" "$tmpdepfile" > "$depfile"
</font> sed '1,2d' "$tmpdepfile" | tr ' ' '
' | \
## Some versions of the HPUX 10.20 sed can't process this invocation
<font color='#006600'>diff -u rtems/mdate-sh:1.1 rtems/mdate-sh:1.2
--- rtems/mdate-sh:1.1 Mon Oct 3 04:38:27 2011
+++ rtems/mdate-sh Mon Dec 12 22:59:22 2011
</font><font color='#997700'>@@ -1,10 +1,10 @@
</font> #!/bin/sh
# Get modification time of a file or directory and pretty-print it.
<font color='#880000'>-scriptversion=2009-04-28.21; # UTC
</font><font color='#000088'>+scriptversion=2010-08-21.06; # UTC
</font>
<font color='#880000'>-# Copyright (C) 1995, 1996, 1997, 2003, 2004, 2005, 2007, 2009 Free
-# Software Foundation, Inc.
</font><font color='#000088'>+# Copyright (C) 1995, 1996, 1997, 2003, 2004, 2005, 2007, 2009, 2010
+# Free Software Foundation, Inc.
</font> # written by Ulrich Drepper <drepper@gnu.ai.mit.edu>, June 1995
#
# This program is free software; you can redistribute it and/or modify
<font color='#997700'>@@ -29,6 +29,15 @@
</font> # bugs to <bug-automake@gnu.org> or send patches to
# <automake-patches@gnu.org>.
<font color='#000088'>+if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
+ emulate sh
+ NULLCMD=:
+ # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
+ # is contrary to our usage. Disable this feature.
+ alias -g '${1+"$@"}'='"$@"'
+ setopt NO_GLOB_SUBST
+fi
+
</font> case $1 in
'')
echo "$0: No file. Try \`$0 --help' for more information." 1>&2
<font color='#997700'>@@ -38,7 +47,8 @@
</font> cat <<\EOF
Usage: mdate-sh [--help] [--version] FILE
<font color='#880000'>-Pretty-print the modification time of FILE.
</font><font color='#000088'>+Pretty-print the modification day of FILE, in the format:
+1 January 1970
</font>
Report bugs to <bug-automake@gnu.org>.
EOF
<font color='#997700'>@@ -50,6 +60,13 @@
</font> ;;
esac
<font color='#000088'>+error ()
+{
+ echo "$0: $1" >&2
+ exit 1
+}
+
+
</font> # Prevent date giving response in another language.
LANG=C
export LANG
<font color='#997700'>@@ -99,6 +116,7 @@
</font> command=
until test $month
do
<font color='#000088'>+ test $# -gt 0 || error "failed parsing \`$ls_command /' output"
</font> shift
# Add another shift to the command.
command="$command shift;"
<font color='#997700'>@@ -118,8 +136,10 @@
</font> esac
done
<font color='#000088'>+test -n "$month" || error "failed parsing \`$ls_command /' output"
+
</font> # Get the extended ls output of the file or directory.
<font color='#880000'>-set dummy x`eval "$ls_command \"\$save_arg1\""`
</font><font color='#000088'>+set dummy x`eval "$ls_command \"\\\$save_arg1\""`
</font>
# Remove all preceding arguments
eval $command
<font color='#006600'>diff -u rtems/texinfo.tex:1.1 rtems/texinfo.tex:1.2
--- rtems/texinfo.tex:1.1 Mon Oct 3 04:38:27 2011
+++ rtems/texinfo.tex Mon Dec 12 22:59:22 2011
</font><font color='#997700'>@@ -3,11 +3,11 @@
</font> % Load plain if necessary, i.e., if running under initex.
\expandafter\ifx\csname fmtname\endcsname\relax\input plain\fi
%
<font color='#880000'>-\def\texinfoversion{2009-08-14.15}
</font><font color='#000088'>+\def\texinfoversion{2011-11-09.15}
</font> %
% Copyright 1985, 1986, 1988, 1990, 1991, 1992, 1993, 1994, 1995,
% 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
<font color='#880000'>-% 2007, 2008, 2009 Free Software Foundation, Inc.
</font><font color='#000088'>+% 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc.
</font> %
% 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
<font color='#997700'>@@ -65,7 +65,6 @@
</font> \everyjob{\message{[Texinfo version \texinfoversion]}%
\catcode`+=\active \catcode`\_=\active}
<font color='#880000'>-
</font> \chardef\other=12
% We never want plain's \outer definition of \+ in Texinfo.
<font color='#997700'>@@ -93,14 +92,13 @@
</font> \let\ptexnewwrite\newwrite
\let\ptexnoindent=\noindent
\let\ptexplus=+
<font color='#000088'>+\let\ptexraggedright=\raggedright
</font> \let\ptexrbrace=\}
\let\ptexslash=\/
\let\ptexstar=\*
\let\ptext=\t
\let\ptextop=\top
<font color='#880000'>-{\catcode`\'=\active
-\global\let\ptexquoteright'}% Math-mode def from plain.tex.
-\let\ptexraggedright=\raggedright
</font><font color='#000088'>+{\catcode`\'=\active \global\let\ptexquoteright'}% active in plain's math mode
</font>
% If this character appears in an error message or help string, it
% starts a new line in the output.
<font color='#997700'>@@ -118,10 +116,11 @@
</font> % Set up fixed words for English if not already set.
\ifx\putwordAppendix\undefined \gdef\putwordAppendix{Appendix}\fi
\ifx\putwordChapter\undefined \gdef\putwordChapter{Chapter}\fi
<font color='#000088'>+\ifx\putworderror\undefined \gdef\putworderror{error}\fi
</font> \ifx\putwordfile\undefined \gdef\putwordfile{file}\fi
\ifx\putwordin\undefined \gdef\putwordin{in}\fi
<font color='#880000'>-\ifx\putwordIndexIsEmpty\undefined \gdef\putwordIndexIsEmpty{(Index is empty)}\fi
-\ifx\putwordIndexNonexistent\undefined \gdef\putwordIndexNonexistent{(Index is nonexistent)}\fi
</font><font color='#000088'>+\ifx\putwordIndexIsEmpty\undefined \gdef\putwordIndexIsEmpty{(Index is empty)}\fi
+\ifx\putwordIndexNonexistent\undefined \gdef\putwordIndexNonexistent{(Index is nonexistent)}\fi
</font> \ifx\putwordInfo\undefined \gdef\putwordInfo{Info}\fi
\ifx\putwordInstanceVariableof\undefined \gdef\putwordInstanceVariableof{Instance Variable of}\fi
\ifx\putwordMethodon\undefined \gdef\putwordMethodon{Method on}\fi
<font color='#997700'>@@ -160,15 +159,18 @@
</font> \def\spaceisspace{\catcode`\ =\spacecat}
% sometimes characters are active, so we need control sequences.
<font color='#000088'>+\chardef\ampChar = `\&
</font> \chardef\colonChar = `\:
\chardef\commaChar = `\,
\chardef\dashChar = `\-
\chardef\dotChar = `\.
\chardef\exclamChar= `\!
<font color='#000088'>+\chardef\hashChar = `\#
</font> \chardef\lquoteChar= `\`
\chardef\questChar = `\?
\chardef\rquoteChar= `\'
\chardef\semiChar = `\;
<font color='#000088'>+\chardef\slashChar = `\/
</font> \chardef\underChar = `\_
% Ignore a token.
<font color='#997700'>@@ -199,36 +201,7 @@
</font> % that mark overfull boxes (in case you have decided
% that the text looks ok even though it passes the margin).
%
<font color='#880000'>-\def\finalout{\overfullrule=0pt}
-
-% @| inserts a changebar to the left of the current line. It should
-% surround any changed text. This approach does *not* work if the
-% change spans more than two lines of output. To handle that, we would
-% have adopt a much more difficult approach (putting marks into the main
-% vertical list for the beginning and end of each change).
-%
-\def\|{%
- % \vadjust can only be used in horizontal mode.
- \leavevmode
- %
- % Append this vertical mode material after the current line in the output.
- \vadjust{%
- % We want to insert a rule with the height and depth of the current
- % leading; that is exactly what \strutbox is supposed to record.
- \vskip-\baselineskip
- %
- % \vadjust-items are inserted at the left edge of the type. So
- % the \llap here moves out into the left-hand margin.
- \llap{%
- %
- % For a thicker or thinner bar, change the `1pt'.
- \vrule height\baselineskip width1pt
- %
- % This is the space between the bar and the text.
- \hskip 12pt
- }%
- }%
-}
</font><font color='#000088'>+\def\finalout{\overfullrule=0pt }
</font>
% Sometimes it is convenient to have everything in the transcript file
% and nothing on the terminal. We don't just call \tracingall here,
<font color='#997700'>@@ -246,7 +219,7 @@
</font> \tracingmacros2
\tracingrestores1
\showboxbreadth\maxdimen \showboxdepth\maxdimen
<font color='#880000'>- \ifx\eTeXversion\undefined\else % etex gives us more logging
</font><font color='#000088'>+ \ifx\eTeXversion\thisisundefined\else % etex gives us more logging
</font> \tracingscantokens1
\tracingifs1
\tracinggroups1
<font color='#997700'>@@ -267,7 +240,6 @@
</font> \def\bigbreak{\ifnum\lastpenalty<10000\par\ifdim\lastskip<\bigskipamount
\removelastskip\penalty-200\bigskip\fi\fi}
<font color='#880000'>-% For @cropmarks command.
</font> % Do @cropmarks to get crop marks.
%
\newif\ifcropmarks
<font color='#997700'>@@ -577,7 +549,7 @@
</font> }
\def\inenvironment#1{%
\ifx#1\empty
<font color='#880000'>- out of any environment%
</font><font color='#000088'>+ outside of any environment%
</font> \else
in environment \expandafter\string#1%
\fi
<font color='#997700'>@@ -589,7 +561,7 @@
</font> \parseargdef\end{%
\if 1\csname iscond.#1\endcsname
\else
<font color='#880000'>- % The general wording of \badenverr may not be ideal, but... --kasal, 06nov03
</font><font color='#000088'>+ % The general wording of \badenverr may not be ideal.
</font> \expandafter\checkenv\csname#1\endcsname
\csname E#1\endcsname
\endgroup
<font color='#997700'>@@ -599,85 +571,6 @@
</font> \newhelp\EMsimple{Press RETURN to continue.}
<font color='#880000'>-%% Simple single-character @ commands
-
-% @@ prints an @
-% Kludge this until the fonts are right (grr).
-\def\@{{\tt\char64}}
-
-% This is turned off because it was never documented
-% and you can use @w{...} around a quote to suppress ligatures.
-%% Define @` and @' to be the same as ` and '
-%% but suppressing ligatures.
-%\def\`{{`}}
-%\def\'{{'}}
-
-% Used to generate quoted braces.
-\def\mylbrace {{\tt\char123}}
-\def\myrbrace {{\tt\char125}}
-\let\{=\mylbrace
-\let\}=\myrbrace
-\begingroup
- % Definitions to produce \{ and \} commands for indices,
- % and @{ and @} for the aux/toc files.
- \catcode`\{ = \other \catcode`\} = \other
- \catcode`\[ = 1 \catcode`\] = 2
- \catcode`\! = 0 \catcode`\\ = \other
- !gdef!lbracecmd[\{]%
- !gdef!rbracecmd[\}]%
- !gdef!lbraceatcmd[@{]%
- !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
-\let\dotaccent = \.
-\def\ringaccent#1{{\accent23 #1}}
-\let\tieaccent = \t
-\let\ubaraccent = \b
-\let\udotaccent = \d
-
-% 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\raise1ex\hbox{\selectfonts\lllsize \underbar{a}}}
-\def\ordm{\leavevmode\raise1ex\hbox{\selectfonts\lllsize \underbar{o}}}
-
-% Dotless i and dotless j, used for accents.
-\def\imacro{i}
-\def\jmacro{j}
-\def\dotless#1{%
- \def\temp{#1}%
- \ifx\temp\imacro \ifmmode\imath \else\ptexi \fi
- \else\ifx\temp\jmacro \ifmmode\jmath \else\j \fi
- \else \errmessage{@dotless can be used only with i or j}%
- \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.)
-%
-\edef\TeX{\TeX \spacefactor=1000 }
-
-% @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
- {\setbox0=\hbox{T}%
- \vbox to \ht0{\hbox{\selectfonts\lllsize A}\vss}}%
- \kern-.15em
- \TeX
-}
-
</font> % 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
<font color='#997700'>@@ -719,7 +612,7 @@
</font> \else\ifx\temp\offword \plainnonfrenchspacing
\else
\errhelp = \EMsimple
<font color='#880000'>- \errmessage{Unknown @frenchspacing option `\temp', must be on/off}%
</font><font color='#000088'>+ \errmessage{Unknown @frenchspacing option `\temp', must be on|off}%
</font> \fi\fi
}
<font color='#997700'>@@ -801,15 +694,6 @@
</font>
\newdimen\mil \mil=0.001in
<font color='#880000'>-% Old definition--didn't work.
-%\parseargdef\need{\par %
-%% This method tries to make TeX break the page naturally
-%% if the depth of the box does not fit.
-%{\baselineskip=0pt%
-%\vtop to #1\mil{\vfil}\kern -#1\mil\nobreak
-%\prevdepth=-1000pt
-%}}
-
</font> \parseargdef\need{%
% Ensure vertical mode, so we don't make a big box in the middle of a
% paragraph.
<font color='#997700'>@@ -873,7 +757,7 @@
</font>
% @inmargin{WHICH}{TEXT} puts TEXT in the WHICH margin next to the current
% paragraph. For more general purposes, use the \margin insertion
<font color='#880000'>-% class. WHICH is `l' or `r'.
</font><font color='#000088'>+% class. WHICH is `l' or `r'. Not documented, written for gawk manual.
</font> %
\newskip\inmarginspacing \inmarginspacing=1cm
\def\strutdepth{\dp\strutbox}
<font color='#997700'>@@ -920,6 +804,36 @@
</font> \temp
}
<font color='#000088'>+% @| inserts a changebar to the left of the current line. It should
+% surround any changed text. This approach does *not* work if the
+% change spans more than two lines of output. To handle that, we would
+% have adopt a much more difficult approach (putting marks into the main
+% vertical list for the beginning and end of each change). This command
+% is not documented, not supported, and doesn't work.
+%
+\def\|{%
+ % \vadjust can only be used in horizontal mode.
+ \leavevmode
+ %
+ % Append this vertical mode material after the current line in the output.
+ \vadjust{%
+ % We want to insert a rule with the height and depth of the current
+ % leading; that is exactly what \strutbox is supposed to record.
+ \vskip-\baselineskip
+ %
+ % \vadjust-items are inserted at the left edge of the type. So
+ % the \llap here moves out into the left-hand margin.
+ \llap{%
+ %
+ % For a thicker or thinner bar, change the `1pt'.
+ \vrule height\baselineskip width1pt
+ %
+ % This is the space between the bar and the text.
+ \hskip 12pt
+ }%
+ }%
+}
+
</font> % @include FILE -- \input text of FILE.
%
\def\include{\parseargusing\filenamecatcodes\includezzz}
<font color='#997700'>@@ -930,6 +844,7 @@
</font> \makevalueexpandable % we want to expand any @value in FILE.
\turnoffactive % and allow special characters in the expansion
\indexnofonts % Allow `@@' and other weird things in file names.
<font color='#000088'>+ \wlog{texinfo.tex: doing @include of #1^^J}%
</font> \edef\temp{\noexpand\input #1 }%
%
% This trickery is to read FILE outside of a group, in case it makes
<font color='#997700'>@@ -1095,109 +1010,6 @@
</font> }
<font color='#880000'>-% @asis just yields its argument. Used with @table, for example.
-%
-\def\asis#1{#1}
-
-% @math outputs its argument in math mode.
-%
-% One complication: _ usually means subscripts, but it could also mean
-% an actual _ character, as in @math{@var{some_variable} + 1}. So make
-% _ active, and distinguish by seeing if the current family is \slfam,
-% which is what @var uses.
-{
- \catcode`\_ = \active
- \gdef\mathunderscore{%
- \catcode`\_=\active
- \def_{\ifnum\fam=\slfam \_\else\sb\fi}%
- }
-}
-% Another complication: we want \\ (and @\) to output a \ character.
-% FYI, plain.tex uses \\ as a temporary control sequence (why?), but
-% this is not advertised and we don't care. Texinfo does not
-% otherwise define @\.
-%
-% The \mathchar is class=0=ordinary, family=7=ttfam, position=5C=\.
-\def\mathbackslash{\ifnum\fam=\ttfam \mathchar"075C \else\backslash \fi}
-%
-\def\math{%
- \tex
- \mathunderscore
- \let\\ = \mathbackslash
- \mathactive
- % make the texinfo accent commands work in math mode
- \let\"=\ddot
- \let\'=\acute
- \let\==\bar
- \let\^=\hat
- \let\`=\grave
- \let\u=\breve
- \let\v=\check
- \let\~=\tilde
- \let\dotaccent=\dot
- $\finishmath
-}
-\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
-% to a command which sets the catcodes (such as @item or @section).
-%
-{
- \catcode`^ = \active
- \catcode`< = \active
- \catcode`> = \active
- \catcode`+ = \active
- \catcode`' = \active
- \gdef\mathactive{%
- \let^ = \ptexhat
- \let< = \ptexless
- \let> = \ptexgtr
- \let+ = \ptexplus
- \let' = \ptexquoteright
- }
-}
-
-% Some math mode symbols.
-\def\bullet{$\ptexbullet$}
-\def\geq{\ifmmode \ge\else $\ge$\fi}
-\def\leq{\ifmmode \le\else $\le$\fi}
-\def\minus{\ifmmode -\else $-$\fi}
-
-% @dots{} outputs an ellipsis using the current font.
-% We do .5em per period so that it has the same spacing in the cm
-% typewriter fonts as three actual period characters; on the other hand,
-% in other typewriter fonts three periods are wider than 1.5em. So do
-% whichever is larger.
-%
-\def\dots{%
- \leavevmode
- \setbox0=\hbox{...}% get width of three periods
- \ifdim\wd0 > 1.5em
- \dimen0 = \wd0
- \else
- \dimen0 = 1.5em
- \fi
- \hbox to \dimen0{%
- \hskip 0pt plus.25fil
- .\hskip 0pt plus1fil
- .\hskip 0pt plus1fil
- .\hskip 0pt plus.5fil
- }%
-}
-
-% @enddots{} is an end-of-sentence ellipsis.
-%
-\def\enddots{%
- \dots
- \spacefactor=\endofsentencespacefactor
-}
-
-% @comma{} is so commas can be inserted into text without messing up
-% Texinfo's parsing.
-%
-\let\comma = ,
-
</font> % @refill is a no-op.
\let\refill=\relax
<font color='#997700'>@@ -1262,9 +1074,8 @@
</font> \newif\ifpdfmakepagedest
% when pdftex is run in dvi mode, \pdfoutput is defined (so \pdfoutput=1
<font color='#880000'>-% can be set). So we test for \relax and 0 as well as \undefined,
-% borrowed from ifpdf.sty.
-\ifx\pdfoutput\undefined
</font><font color='#000088'>+% can be set). So we test for \relax and 0 as well as being undefined.
+\ifx\pdfoutput\thisisundefined
</font> \else
\ifx\pdfoutput\relax
\else
<font color='#997700'>@@ -1384,29 +1195,31 @@
</font> \def\imagewidth{#2}\setbox0 = \hbox{\ignorespaces #2}%
\def\imageheight{#3}\setbox2 = \hbox{\ignorespaces #3}%
%
<font color='#880000'>- % pdftex (and the PDF format) support .png, .jpg, .pdf (among
- % others). Let's try in that order.
</font><font color='#000088'>+ % pdftex (and the PDF format) support .pdf, .png, .jpg (among
+ % others). Let's try in that order, PDF first since if
+ % someone has a scalable image, presumably better to use that than a
+ % bitmap.
</font> \let\pdfimgext=\empty
\begingroup
<font color='#880000'>- \openin 1 #1.png \ifeof 1
- \openin 1 #1.jpg \ifeof 1
- \openin 1 #1.jpeg \ifeof 1
- \openin 1 #1.JPG \ifeof 1
- \openin 1 #1.pdf \ifeof 1
- \openin 1 #1.PDF \ifeof 1
</font><font color='#000088'>+ \openin 1 #1.pdf \ifeof 1
+ \openin 1 #1.PDF \ifeof 1
+ \openin 1 #1.png \ifeof 1
+ \openin 1 #1.jpg \ifeof 1
+ \openin 1 #1.jpeg \ifeof 1
+ \openin 1 #1.JPG \ifeof 1
</font> \errhelp = \nopdfimagehelp
\errmessage{Could not find image file #1 for pdf}%
<font color='#880000'>- \else \gdef\pdfimgext{PDF}%
</font><font color='#000088'>+ \else \gdef\pdfimgext{JPG}%
</font> \fi
<font color='#880000'>- \else \gdef\pdfimgext{pdf}%
</font><font color='#000088'>+ \else \gdef\pdfimgext{jpeg}%
</font> \fi
<font color='#880000'>- \else \gdef\pdfimgext{JPG}%
</font><font color='#000088'>+ \else \gdef\pdfimgext{jpg}%
</font> \fi
<font color='#880000'>- \else \gdef\pdfimgext{jpeg}%
</font><font color='#000088'>+ \else \gdef\pdfimgext{png}%
</font> \fi
<font color='#880000'>- \else \gdef\pdfimgext{jpg}%
</font><font color='#000088'>+ \else \gdef\pdfimgext{PDF}%
</font> \fi
<font color='#880000'>- \else \gdef\pdfimgext{png}%
</font><font color='#000088'>+ \else \gdef\pdfimgext{pdf}%
</font> \fi
\closein 1
\endgroup
<font color='#997700'>@@ -1492,6 +1305,7 @@
</font> \edef\myrbrace{\iffalse{\else\string}\fi}\let\}=\myrbrace
%
% Read toc silently, to get counts of subentries for \pdfoutline.
<font color='#000088'>+ \def\partentry##1##2##3##4{}% ignore parts in the outlines
</font> \def\numchapentry##1##2##3##4{%
\def\thischapnum{##2}%
\def\thissecnum{0}%
<font color='#997700'>@@ -1695,7 +1509,7 @@
</font> % if we are producing pdf, and we have \pdffontattr, then define cmaps.
% (\pdffontattr was introduced many years ago, but people still run
% older pdftex's; it's easy to conditionalize, so we do.)
<font color='#880000'>-\ifpdf \ifx\pdffontattr\undefined \else
</font><font color='#000088'>+\ifpdf \ifx\pdffontattr\thisisundefined \else
</font> \begingroup
\catcode`\^^M=\active \def^^M{^^J}% Output line endings as the ^^J char.
\catcode`\%=12 \immediate\pdfobj stream {%!PS-Adobe-3.0 Resource-CMap
<font color='#997700'>@@ -1962,7 +1776,7 @@
</font> % Use cm as the default font prefix.
% To specify the font prefix, you must define \fontprefix
% before you read in texinfo.tex.
<font color='#880000'>-\ifx\fontprefix\undefined
</font><font color='#000088'>+\ifx\fontprefix\thisisundefined
</font> \def\fontprefix{cm}
\fi
% Support font families that don't use the same naming scheme as CM.
<font color='#997700'>@@ -2105,8 +1919,8 @@
</font> \font\reducedsy=cmsy10
\def\reducedecsize{1000}
<font color='#880000'>-% reset the current fonts
-\textfonts
</font><font color='#000088'>+\textleading = 13.2pt % line spacing for 11pt CM
+\textfonts % reset the current fonts
</font> \rm
} % end of 11pt text font size definitions
<font color='#997700'>@@ -2236,11 +2050,9 @@
</font> \font\reducedsy=cmsy9
\def\reducedecsize{0900}
<font color='#880000'>-% reduce space between paragraphs
-\divide\parskip by 2
-
-% reset the current fonts
-\textfonts
</font><font color='#000088'>+\divide\parskip by 2 % reduce space between paragraphs
+\textleading = 12pt % line spacing for 10pt CM
+\textfonts % reset the current fonts
</font> \rm
} % end of 10pt text font size definitions
<font color='#997700'>@@ -2249,12 +2061,13 @@
</font> % @fonttextsize 10
% (or 11) to redefine the text font size. pt is assumed.
%
<font color='#880000'>-\def\xword{10}
</font> \def\xiword{11}
<font color='#000088'>+\def\xword{10}
+\def\xwordpt{10pt}
</font> %
\parseargdef\fonttextsize{%
\def\textsizearg{#1}%
<font color='#880000'>- \wlog{doing @fonttextsize \textsizearg}%
</font><font color='#000088'>+ %\wlog{doing @fonttextsize \textsizearg}%
</font> %
% Set \globaldefs so that documents can use this inside @tex, since
% makeinfo 4.8 does not support it, but we need it nonetheless.
<font color='#997700'>@@ -2308,7 +2121,7 @@
</font> \let\tenttsl=\titlettsl
\def\curfontsize{title}%
\def\lsize{chap}\def\lllsize{subsec}%
<font color='#880000'>- \resetmathfonts \setleading{25pt}}
</font><font color='#000088'>+ \resetmathfonts \setleading{27pt}}
</font> \def\titlefont#1{{\titlefonts\rmisbold #1}}
\def\chapfonts{%
\let\tenrm=\chaprm \let\tenit=\chapit \let\tensl=\chapsl
<font color='#997700'>@@ -2436,12 +2249,14 @@
</font>
% Markup style setup for left and right quotes.
\defmarkupstylesetup\markupsetuplq{%
<font color='#880000'>- \expandafter\let\expandafter \temp \csname markupsetuplq\currentmarkupstyle\endcsname
</font><font color='#000088'>+ \expandafter\let\expandafter \temp
+ \csname markupsetuplq\currentmarkupstyle\endcsname
</font> \ifx\temp\relax \markupsetuplqdefault \else \temp \fi
}
\defmarkupstylesetup\markupsetuprq{%
<font color='#880000'>- \expandafter\let\expandafter \temp \csname markupsetuprq\currentmarkupstyle\endcsname
</font><font color='#000088'>+ \expandafter\let\expandafter \temp
+ \csname markupsetuprq\currentmarkupstyle\endcsname
</font> \ifx\temp\relax \markupsetuprqdefault \else \temp \fi
}
<font color='#997700'>@@ -2460,22 +2275,26 @@
</font>
\let\markupsetuplqcode \markupsetcodequoteleft
\let\markupsetuprqcode \markupsetcodequoteright
<font color='#000088'>+%
</font> \let\markupsetuplqexample \markupsetcodequoteleft
\let\markupsetuprqexample \markupsetcodequoteright
<font color='#000088'>+%
+\let\markupsetuplqsamp \markupsetcodequoteleft
+\let\markupsetuprqsamp \markupsetcodequoteright
+%
</font> \let\markupsetuplqverb \markupsetcodequoteleft
\let\markupsetuprqverb \markupsetcodequoteright
<font color='#000088'>+%
</font> \let\markupsetuplqverbatim \markupsetcodequoteleft
\let\markupsetuprqverbatim \markupsetcodequoteright
<font color='#880000'>-\let\markupsetuplqsamp \markupsetnoligaturesquoteleft
</font> \let\markupsetuplqkbd \markupsetnoligaturesquoteleft
<font color='#880000'>-% Allow an option to not replace quotes with a regular directed right
-% quote/apostrophe (char 0x27), but instead use the undirected quote
-% from cmtt (char 0x0d). The undirected quote is ugly, so don't make it
-% the default, but it works for pasting with more pdf viewers (at least
-% evince), the lilypond developers report. xpdf does work with the
-% regular 0x27.
</font><font color='#000088'>+% Allow an option to not use regular directed right quote/apostrophe
+% (char 0x27), but instead the undirected quote from cmtt (char 0x0d).
+% The undirected quote is ugly, so don't make it the default, but it
+% works for pasting with more pdf viewers (at least evince), the
+% lilypond developers report. xpdf does work with the regular 0x27.
</font> %
\def\codequoteright{%
\expandafter\ifx\csname SETtxicodequoteundirected\endcsname\relax
<font color='#997700'>@@ -2499,33 +2318,84 @@
</font> \else \char'22 \fi
}
<font color='#000088'>+% Commands to set the quote options.
+%<span style="background-color: #FF0000"> </span>
+\parseargdef\codequoteundirected{%
+ \def\temp{#1}%
+ \ifx\temp\onword
+ \expandafter\let\csname SETtxicodequoteundirected\endcsname
+ = t%
+ \else\ifx\temp\offword
+ \expandafter\let\csname SETtxicodequoteundirected\endcsname
+ = \relax
+ \else
+ \errhelp = \EMsimple
+ \errmessage{Unknown @codequoteundirected value `\temp', must be on|off}%
+ \fi\fi
+}
+%
+\parseargdef\codequotebacktick{%
+ \def\temp{#1}%
+ \ifx\temp\onword
+ \expandafter\let\csname SETtxicodequotebacktick\endcsname
+ = t%
+ \else\ifx\temp\offword
+ \expandafter\let\csname SETtxicodequotebacktick\endcsname
+ = \relax
+ \else
+ \errhelp = \EMsimple
+ \errmessage{Unknown @codequotebacktick value `\temp', must be on|off}%
+ \fi\fi
+}
+
</font> % [Knuth] pp. 380,381,391, disable Spanish ligatures ?` and !` of \tt font.
\def\noligaturesquoteleft{\relax\lq}
% Count depth in font-changes, for error checks
\newcount\fontdepth \fontdepth=0
<font color='#880000'>-%% Add scribe-like font environments, plus @l for inline lisp (usually sans
-%% serif) and @ii for TeX italic
</font><font color='#000088'>+% Font commands.
</font>
<font color='#880000'>-% \smartitalic{ARG} outputs arg in italics, followed by an italic correction
-% unless the following character is such as not to need one.
-\def\smartitalicx{\ifx\next,\else\ifx\next-\else\ifx\next.\else
- \ptexslash\fi\fi\fi}
-\def\smartslanted#1{{\ifusingtt\ttsl\sl #1}\futurelet\next\smartitalicx}
-\def\smartitalic#1{{\ifusingtt\ttsl\it #1}\futurelet\next\smartitalicx}
</font><font color='#000088'>+% #1 is the font command (\sl or \it), #2 is the text to slant.
+% If we are in a monospaced environment, however, 1) always use \ttsl,
+% and 2) do not add an italic correction.
+\def\dosmartslant#1#2{%
+ \ifusingtt<span style="background-color: #FF0000"> </span>
+ {{\ttsl #2}\let\next=\relax}%
+ {\def\next{{#1#2}\futurelet\next\smartitaliccorrection}}%
+ \next
+}
+\def\smartslanted{\dosmartslant\sl}
+\def\smartitalic{\dosmartslant\it}
+
+% Output an italic correction unless \next (presumed to be the following
+% character) is such as not to need one.
+\def\smartitaliccorrection{%
+ \ifx\next,%
+ \else\ifx\next-%
+ \else\ifx\next.%
+ \else\ptexslash
+ \fi\fi\fi
+ \aftersmartic
+}
</font>
<font color='#880000'>-% like \smartslanted except unconditionally uses \ttsl.
</font><font color='#000088'>+% like \smartslanted except unconditionally uses \ttsl, and no ic.
</font> % @var is set to this for defun arguments.
<font color='#880000'>-\def\ttslanted#1{{\ttsl #1}\futurelet\next\smartitalicx}
</font><font color='#000088'>+\def\ttslanted#1{{\ttsl #1}}
</font>
% @cite is like \smartslanted except unconditionally use \sl. We never want
% ttsl for book titles, do we?
<font color='#880000'>-\def\cite#1{{\sl #1}\futurelet\next\smartitalicx}
</font><font color='#000088'>+\def\cite#1{{\sl #1}\futurelet\next\smartitaliccorrection}
+
+\def\aftersmartic{}
+\def\var#1{%
+ \let\saveaftersmartic = \aftersmartic
+ \def\aftersmartic{\null\let\aftersmartic=\saveaftersmartic}%
+ \smartslanted{#1}%
+}
</font>
\let\i=\smartitalic
\let\slanted=\smartslanted
<font color='#880000'>-\def\var#1{{\setupmarkupstyle{var}\smartslanted{#1}}}
</font> \let\dfn=\smartslanted
\let\emph=\smartitalic
<font color='#997700'>@@ -2621,7 +2491,7 @@
</font> \plainfrenchspacing
#1%
}%
<font color='#880000'>- \null
</font><font color='#000088'>+ \null % reset spacefactor to 1000
</font> }
% We *must* turn on hyphenation at `-' and `_' in @code.
<font color='#997700'>@@ -2653,6 +2523,8 @@
</font> }
}
<font color='#000088'>+\def\codex #1{\tclose{#1}\endgroup}
+
</font> \def\realdash{-}
\def\codedash{-\discretionary{}{}{}}
\def\codeunder{%
<font color='#997700'>@@ -2666,7 +2538,6 @@
</font> \discretionary{}{}{}}%
{\_}%
}
<font color='#880000'>-\def\codex #1{\tclose{#1}\endgroup}
</font>
% An additional complication: the above will allow breaks after, e.g.,
% each of the four underscores in __typeof__. This is undesirable in
<font color='#997700'>@@ -2686,10 +2557,156 @@
</font> \allowcodebreaksfalse
\else
\errhelp = \EMsimple
<font color='#880000'>- \errmessage{Unknown @allowcodebreaks option `\txiarg'}%
</font><font color='#000088'>+ \errmessage{Unknown @allowcodebreaks option `\txiarg', must be true|false}%
</font> \fi\fi
}
<font color='#000088'>+% @uref (abbreviation for `urlref') takes an optional (comma-separated)
+% second argument specifying the text to display and an optional third
+% arg as text to display instead of (rather than in addition to) the url
+% itself. First (mandatory) arg is the url.
+% (This \urefnobreak definition isn't used now, leaving it for a while
+% for comparison.)
+\def\urefnobreak#1{\dourefnobreak #1,,,\finish}
+\def\dourefnobreak#1,#2,#3,#4\finish{\begingroup
+ \unsepspaces
+ \pdfurl{#1}%
+ \setbox0 = \hbox{\ignorespaces #3}%
+ \ifdim\wd0 > 0pt
+ \unhbox0 % third arg given, show only that
+ \else
+ \setbox0 = \hbox{\ignorespaces #2}%
+ \ifdim\wd0 > 0pt
+ \ifpdf
+ \unhbox0 % PDF: 2nd arg given, show only it
+ \else
+ \unhbox0\ (\code{#1})% DVI: 2nd arg given, show both it and url
+ \fi
+ \else
+ \code{#1}% only url given, so show it
+ \fi
+ \fi
+ \endlink
+\endgroup}
+
+% This \urefbreak definition is the active one.
+\def\urefbreak{\begingroup \urefcatcodes \dourefbreak}
+\let\uref=\urefbreak
+\def\dourefbreak#1{\urefbreakfinish #1,,,\finish}
+\def\urefbreakfinish#1,#2,#3,#4\finish{% doesn't work in @example
+ \unsepspaces
+ \pdfurl{#1}%
+ \setbox0 = \hbox{\ignorespaces #3}%
+ \ifdim\wd0 > 0pt
+ \unhbox0 % third arg given, show only that
+ \else
+ \setbox0 = \hbox{\ignorespaces #2}%
+ \ifdim\wd0 > 0pt
+ \ifpdf
+ \unhbox0 % PDF: 2nd arg given, show only it
+ \else
+ \unhbox0\ (\urefcode{#1})% DVI: 2nd arg given, show both it and url
+ \fi
+ \else
+ \urefcode{#1}% only url given, so show it
+ \fi
+ \fi
+ \endlink
+\endgroup}
+
+% Allow line breaks around only a few characters (only).
+\def\urefcatcodes{%
+ \catcode\ampChar=\active \catcode\dotChar=\active
+ \catcode\hashChar=\active \catcode\questChar=\active
+ \catcode\slashChar=\active
+}
+{
+ \urefcatcodes
+ %
+ \global\def\urefcode{\begingroup
+ \setupmarkupstyle{code}%
+ \urefcatcodes
+ \let&\urefcodeamp
+ \let.\urefcodedot
+ \let#\urefcodehash
+ \let?\urefcodequest
+ \let/\urefcodeslash
+ \codex
+ }
+ %
+ % By default, they are just regular characters.
+ \global\def&{\normalamp}
+ \global\def.{\normaldot}
+ \global\def#{\normalhash}
+ \global\def?{\normalquest}
+ \global\def/{\normalslash}
+}
+
+% we put a little stretch before and after the breakable chars, to help
+% line breaking of long url's. The unequal skips make look better in
+% cmtt at least, especially for dots.
+\def\urefprestretch{\urefprebreak \hskip0pt plus.13em }
+\def\urefpoststretch{\urefpostbreak \hskip0pt plus.1em }
+%
+\def\urefcodeamp{\urefprestretch \&\urefpoststretch}
+\def\urefcodedot{\urefprestretch .\urefpoststretch}
+\def\urefcodehash{\urefprestretch \#\urefpoststretch}
+\def\urefcodequest{\urefprestretch ?\urefpoststretch}
+\def\urefcodeslash{\futurelet\next\urefcodeslashfinish}
+{
+ \catcode`\/=\active
+ \global\def\urefcodeslashfinish{%
+ \urefprestretch \slashChar
+ % Allow line break only after the final / in a sequence of
+ % slashes, to avoid line break between the slashes in http://.
+ \ifx\next/\else \urefpoststretch \fi
+ }
+}
+
+% One more complication: by default we'll break after the special
+% characters, but some people like to break before the special chars, so
+% allow that. Also allow no breaking at all, for manual control.
+%<span style="background-color: #FF0000"> </span>
+\parseargdef\urefbreakstyle{%
+ \def\txiarg{#1}%
+ \ifx\txiarg\wordnone
+ \def\urefprebreak{\nobreak}\def\urefpostbreak{\nobreak}
+ \else\ifx\txiarg\wordbefore
+ \def\urefprebreak{\allowbreak}\def\urefpostbreak{\nobreak}
+ \else\ifx\txiarg\wordafter
+ \def\urefprebreak{\nobreak}\def\urefpostbreak{\allowbreak}
+ \else
+ \errhelp = \EMsimple
+ \errmessage{Unknown @urefbreakstyle setting `\txiarg'}%
+ \fi\fi\fi
+}
+\def\wordafter{after}
+\def\wordbefore{before}
+\def\wordnone{none}
+
+\urefbreakstyle after
+
+% @url synonym for @uref, since that's how everyone uses it.
+%
+\let\url=\uref
+
+% rms does not like angle brackets --karl, 17may97.
+% So now @email is just like @uref, unless we are pdf.
+%
+%\def\email#1{\angleleft{\tt #1}\angleright}
+\ifpdf
+ \def\email#1{\doemail#1,,\finish}
+ \def\doemail#1,#2,#3\finish{\begingroup
+ \unsepspaces
+ \pdfurl{mailto:#1}%
+ \setbox0 = \hbox{\ignorespaces #2}%
+ \ifdim\wd0>0pt\unhbox0\else\code{#1}\fi
+ \endlink
+ \endgroup}
+\else
+ \let\email=\uref
+\fi
+
</font> % @kbd is like @code, except that if the argument is just one @key command,
% then @kbd has no effect.
\def\kbd#1{{\setupmarkupstyle{kbd}\def\look{#1}\expandafter\kbdfoo\look??\par}}
<font color='#997700'>@@ -2707,7 +2724,7 @@
</font> \gdef\kbdexamplefont{\tt}\gdef\kbdfont{\tt}%
\else
\errhelp = \EMsimple
<font color='#880000'>- \errmessage{Unknown @kbdinputstyle option `\txiarg'}%
</font><font color='#000088'>+ \errmessage{Unknown @kbdinputstyle setting `\txiarg'}%
</font> \fi\fi\fi
}
\def\worddistinct{distinct}
<font color='#997700'>@@ -2735,93 +2752,226 @@
</font> \parseargdef\clickstyle{\def\click{#1}}
\def\click{\arrow}
<font color='#880000'>-% @uref (abbreviation for `urlref') takes an optional (comma-separated)
-% second argument specifying the text to display and an optional third
-% arg as text to display instead of (rather than in addition to) the url
-% itself. First (mandatory) arg is the url. Perhaps eventually put in
-% a hypertex \special here.
</font><font color='#000088'>+% Typeset a dimension, e.g., `in' or `pt'. The only reason for the
+% argument is to make the input look right: @dmn{pt} instead of @dmn{}pt.
</font> %
<font color='#880000'>-\def\uref#1{\douref #1,,,\finish}
-\def\douref#1,#2,#3,#4\finish{\begingroup
- \unsepspaces
- \pdfurl{#1}%
- \setbox0 = \hbox{\ignorespaces #3}%
- \ifdim\wd0 > 0pt
- \unhbox0 % third arg given, show only that
- \else
- \setbox0 = \hbox{\ignorespaces #2}%
- \ifdim\wd0 > 0pt
- \ifpdf
- \unhbox0 % PDF: 2nd arg given, show only it
- \else
- \unhbox0\ (\code{#1})% DVI: 2nd arg given, show both it and url
- \fi
- \else
- \code{#1}% only url given, so show it
- \fi
</font><font color='#000088'>+\def\dmn#1{\thinspace #1}
+
+% @l was never documented to mean ``switch to the Lisp font'',
+% and it is not used as such in any manual I can find. We need it for
+% Polish suppressed-l. --karl, 22sep96.
+%\def\l#1{{\li #1}\null}
+
+% @acronym for "FBI", "NATO", and the like.
+% We print this one point size smaller, since it's intended for
+% all-uppercase.
+%
+\def\acronym#1{\doacronym #1,,\finish}
+\def\doacronym#1,#2,#3\finish{%
+ {\selectfonts\lsize #1}%
+ \def\temp{#2}%
+ \ifx\temp\empty \else
+ \space ({\unsepspaces \ignorespaces \temp \unskip})%
</font> \fi
<font color='#880000'>- \endlink
-\endgroup}
</font><font color='#000088'>+ \null % reset \spacefactor=1000
+}
</font>
<font color='#880000'>-% @url synonym for @uref, since that's how everyone uses it.
</font><font color='#000088'>+% @abbr for "Comput. J." and the like.
+% No font change, but don't do end-of-sentence spacing.
</font> %
<font color='#880000'>-\let\url=\uref
</font><font color='#000088'>+\def\abbr#1{\doabbr #1,,\finish}
+\def\doabbr#1,#2,#3\finish{%
+ {\plainfrenchspacing #1}%
+ \def\temp{#2}%
+ \ifx\temp\empty \else
+ \space ({\unsepspaces \ignorespaces \temp \unskip})%
+ \fi
+ \null % reset \spacefactor=1000
+}
+
+% @asis just yields its argument. Used with @table, for example.
+%
+\def\asis#1{#1}
+
+% @math outputs its argument in math mode.
+%
+% One complication: _ usually means subscripts, but it could also mean
+% an actual _ character, as in @math{@var{some_variable} + 1}. So make
+% _ active, and distinguish by seeing if the current family is \slfam,
+% which is what @var uses.
+{
+ \catcode`\_ = \active
+ \gdef\mathunderscore{%
+ \catcode`\_=\active
+ \def_{\ifnum\fam=\slfam \_\else\sb\fi}%
+ }
+}
+% Another complication: we want \\ (and @\) to output a math (or tt) \.
+% FYI, plain.tex uses \\ as a temporary control sequence (for no
+% particular reason), but this is not advertised and we don't care.
+%
+% The \mathchar is class=0=ordinary, family=7=ttfam, position=5C=\.
+\def\mathbackslash{\ifnum\fam=\ttfam \mathchar"075C \else\backslash \fi}
+%
+\def\math{%
+ \tex
+ \mathunderscore
+ \let\\ = \mathbackslash
+ \mathactive
+ % make the texinfo accent commands work in math mode
+ \let\"=\ddot
+ \let\'=\acute
+ \let\==\bar
+ \let\^=\hat
+ \let\`=\grave
+ \let\u=\breve
+ \let\v=\check
+ \let\~=\tilde
+ \let\dotaccent=\dot
+ $\finishmath
+}
+\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
+% to a command which sets the catcodes (such as @item or @section).
+%
+{
+ \catcode`^ = \active
+ \catcode`< = \active
+ \catcode`> = \active
+ \catcode`+ = \active
+ \catcode`' = \active
+ \gdef\mathactive{%
+ \let^ = \ptexhat
+ \let< = \ptexless
+ \let> = \ptexgtr
+ \let+ = \ptexplus
+ \let' = \ptexquoteright
+ }
+}
+
+
+\message{glyphs,}
+% and logos.
+
+% @@ prints an @.
+\def\@{\char64 }
+
+% Used to generate quoted braces. Unless we're in typewriter, use
+% \ecfont because the CM text fonts do not have braces, and we don't
+% want to switch into math.
+\def\mylbrace{{\ifmonospace\else\ecfont\fi \char123}}
+\def\myrbrace{{\ifmonospace\else\ecfont\fi \char125}}
+\let\{=\mylbrace
+\let\}=\myrbrace
+\begingroup
+ % Definitions to produce \{ and \} commands for indices,
+ % and @{ and @} for the aux/toc files.
+ \catcode`\{ = \other \catcode`\} = \other
+ \catcode`\[ = 1 \catcode`\] = 2
+ \catcode`\! = 0 \catcode`\\ = \other
+ !gdef!lbracecmd[\{]%
+ !gdef!rbracecmd[\}]%
+ !gdef!lbraceatcmd[@{]%
+ !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\, = \ptexc
+\let\dotaccent = \ptexdot
+\def\ringaccent#1{{\accent23 #1}}
+\let\tieaccent = \ptext
+\let\ubaraccent = \ptexb
+\let\udotaccent = \d
+
+% 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\raise1ex\hbox{\selectfonts\lllsize \underbar{a}}}
+\def\ordm{\leavevmode\raise1ex\hbox{\selectfonts\lllsize \underbar{o}}}
</font>
<font color='#880000'>-% rms does not like angle brackets --karl, 17may97.
-% So now @email is just like @uref, unless we are pdf.
</font><font color='#000088'>+% Dotless i and dotless j, used for accents.
+\def\imacro{i}
+\def\jmacro{j}
+\def\dotless#1{%
+ \def\temp{#1}%
+ \ifx\temp\imacro \ifmmode\imath \else\ptexi \fi
+ \else\ifx\temp\jmacro \ifmmode\jmath \else\j \fi
+ \else \errmessage{@dotless can be used only with i or j}%
+ \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.)
</font> %
<font color='#880000'>-%\def\email#1{\angleleft{\tt #1}\angleright}
-\ifpdf
- \def\email#1{\doemail#1,,\finish}
- \def\doemail#1,#2,#3\finish{\begingroup
- \unsepspaces
- \pdfurl{mailto:#1}%
- \setbox0 = \hbox{\ignorespaces #2}%
- \ifdim\wd0>0pt\unhbox0\else\code{#1}\fi
- \endlink
- \endgroup}
-\else
- \let\email=\uref
-\fi
</font><font color='#000088'>+\edef\TeX{\TeX \spacefactor=1000 }
</font>
<font color='#880000'>-% Typeset a dimension, e.g., `in' or `pt'. The only reason for the
-% argument is to make the input look right: @dmn{pt} instead of @dmn{}pt.
</font><font color='#000088'>+% @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).
</font> %
<font color='#880000'>-\def\dmn#1{\thinspace #1}
</font><font color='#000088'>+\def\LaTeX{%
+ L\kern-.36em
+ {\setbox0=\hbox{T}%
+ \vbox to \ht0{\hbox{%
+ \ifx\textnominalsize\xwordpt
+ % for 10pt running text, \lllsize (8pt) is too small for the A in LaTeX.
+ % Revert to plain's \scriptsize, which is 7pt.
+ \count255=\the\fam $\fam\count255 \scriptstyle A$%
+ \else
+ % For 11pt, we can use our lllsize.
+ \selectfonts\lllsize A%
+ \fi
+ }%
+ \vss
+ }}%
+ \kern-.15em
+ \TeX
+}
</font>
<font color='#880000'>-% @l was never documented to mean ``switch to the Lisp font'',
-% and it is not used as such in any manual I can find. We need it for
-% Polish suppressed-l. --karl, 22sep96.
-%\def\l#1{{\li #1}\null}
</font><font color='#000088'>+% Some math mode symbols.
+\def\bullet{$\ptexbullet$}
+\def\geq{\ifmmode \ge\else $\ge$\fi}
+\def\leq{\ifmmode \le\else $\le$\fi}
+\def\minus{\ifmmode -\else $-$\fi}
</font>
<font color='#880000'>-% @acronym for "FBI", "NATO", and the like.
-% We print this one point size smaller, since it's intended for
-% all-uppercase.
</font><font color='#000088'>+% @dots{} outputs an ellipsis using the current font.
+% We do .5em per period so that it has the same spacing in the cm
+% typewriter fonts as three actual period characters; on the other hand,
+% in other typewriter fonts three periods are wider than 1.5em. So do
+% whichever is larger.
</font> %
<font color='#880000'>-\def\acronym#1{\doacronym #1,,\finish}
-\def\doacronym#1,#2,#3\finish{%
- {\selectfonts\lsize #1}%
- \def\temp{#2}%
- \ifx\temp\empty \else
- \space ({\unsepspaces \ignorespaces \temp \unskip})%
</font><font color='#000088'>+\def\dots{%
+ \leavevmode
+ \setbox0=\hbox{...}% get width of three periods
+ \ifdim\wd0 > 1.5em
+ \dimen0 = \wd0
+ \else
+ \dimen0 = 1.5em
</font> \fi
<font color='#000088'>+ \hbox to \dimen0{%
+ \hskip 0pt plus.25fil
+ .\hskip 0pt plus1fil
+ .\hskip 0pt plus1fil
+ .\hskip 0pt plus.5fil
+ }%
</font> }
<font color='#880000'>-% @abbr for "Comput. J." and the like.
-% No font change, but don't do end-of-sentence spacing.
</font><font color='#000088'>+% @enddots{} is an end-of-sentence ellipsis.
</font> %
<font color='#880000'>-\def\abbr#1{\doabbr #1,,\finish}
-\def\doabbr#1,#2,#3\finish{%
- {\plainfrenchspacing #1}%
- \def\temp{#2}%
- \ifx\temp\empty \else
- \space ({\unsepspaces \ignorespaces \temp \unskip})%
- \fi
</font><font color='#000088'>+\def\enddots{%
+ \dots
+ \spacefactor=\endofsentencespacefactor
</font> }
<font color='#880000'>-
-\message{glyphs,}
-
</font> % @point{}, @result{}, @expansion{}, @print{}, @equiv{}.
%
% Since these characters are used in examples, they should be an even number of
<font color='#997700'>@@ -2842,7 +2992,7 @@
</font> {\tentt \global\dimen0 = 3em}% Width of the box.
\dimen2 = .55pt % Thickness of rules
% The text. (`r' is open on the right, `e' somewhat less so on the left.)
<font color='#880000'>-\setbox0 = \hbox{\kern-.75pt \reducedsf error\kern-1.5pt}
</font><font color='#000088'>+\setbox0 = \hbox{\kern-.75pt \reducedsf \putworderror\kern-1.5pt}
</font> %
\setbox\errorbox=\hbox to \dimen0{\hfil
\hsize = \dimen0 \advance\hsize by -5.8pt % Space to left+right.
<font color='#997700'>@@ -2991,7 +3141,7 @@
</font> % Textures 1.7.7 (preloaded format=plain 93.10.14) (68K) 16 APR 2004 02:38
% so we'll define it if necessary.
%
<font color='#880000'>-\ifx\Orb\undefined
</font><font color='#000088'>+\ifx\Orb\thisisundefined
</font> \def\Orb{\mathhexbox20D}
\fi
<font color='#997700'>@@ -3019,8 +3169,9 @@
</font> \newif\ifsetshortcontentsaftertitlepage
\let\setshortcontentsaftertitlepage = \setshortcontentsaftertitlepagetrue
<font color='#880000'>-\parseargdef\shorttitlepage{\begingroup\hbox{}\vskip 1.5in \chaprm \centerline{#1}%
- \endgroup\page\hbox{}\page}
</font><font color='#000088'>+\parseargdef\shorttitlepage{%
+ \begingroup \hbox{}\vskip 1.5in \chaprm \centerline{#1}%
+ \endgroup\page\hbox{}\page}
</font>
\envdef\titlepage{%
% Open one extra group, as we want to close it in the middle of \Etitlepage.
<font color='#997700'>@@ -3080,7 +3231,7 @@
</font> \finishedtitlepagetrue
}
<font color='#880000'>-%%% Macros to be used within @titlepage:
</font><font color='#000088'>+% Macros to be used within @titlepage:
</font>
\let\subtitlerm=\tenrm
\def\subtitlefont{\subtitlerm \normalbaselineskip = 13pt \normalbaselines}
<font color='#997700'>@@ -3113,7 +3264,7 @@
</font> }
<font color='#880000'>-%%% Set up page headings and footings.
</font><font color='#000088'>+% Set up page headings and footings.
</font>
\let\thispage=\folio
<font color='#997700'>@@ -3207,10 +3358,14 @@
</font>
\def\headings #1 {\csname HEADINGS#1\endcsname}
<font color='#880000'>-\def\HEADINGSoff{%
-\global\evenheadline={\hfil} \global\evenfootline={\hfil}
-\global\oddheadline={\hfil} \global\oddfootline={\hfil}}
-\HEADINGSoff
</font><font color='#000088'>+\def\headingsoff{% non-global headings elimination
+ \evenheadline={\hfil}\evenfootline={\hfil}%
+ \oddheadline={\hfil}\oddfootline={\hfil}%
+}
+
+\def\HEADINGSoff{{\globaldefs=1 \headingsoff}} % global setting
+\HEADINGSoff % it's the default
+
</font> % When we turn headings on, set the page number to 1.
% For double-sided printing, put current file name in lower left corner,
% chapter name on inside top of right hand pages, document
<font color='#997700'>@@ -3261,7 +3416,7 @@
</font> % This produces Day Month Year style of output.
% Only define if not already defined, in case a txi-??.tex file has set
% up a different format (e.g., txi-cs.tex does this).
<font color='#880000'>-\ifx\today\undefined
</font><font color='#000088'>+\ifx\today\thisisundefined
</font> \def\today{%
\number\day\space
\ifcase\month
<font color='#997700'>@@ -3322,7 +3477,7 @@
</font> \begingroup
\advance\leftskip by-\tableindent
\advance\hsize by\tableindent
<font color='#880000'>- \advance\rightskip by0pt plus1fil
</font><font color='#000088'>+ \advance\rightskip by0pt plus1fil\relax
</font> \leavevmode\unhbox0\par
\endgroup
%
<font color='#997700'>@@ -3808,18 +3963,18 @@
</font> \setbox0=\vbox{X}\global\multitablelinespace=\the\baselineskip
\global\advance\multitablelinespace by-\ht0
\fi
<font color='#880000'>-%% Test to see if parskip is larger than space between lines of
-%% table. If not, do nothing.
-%% If so, set to same dimension as multitablelinespace.
</font><font color='#000088'>+% Test to see if parskip is larger than space between lines of
+% table. If not, do nothing.
+% If so, set to same dimension as multitablelinespace.
</font> \ifdim\multitableparskip>\multitablelinespace
\global\multitableparskip=\multitablelinespace
<font color='#880000'>-\global\advance\multitableparskip-7pt %% to keep parskip somewhat smaller
- %% than skip between lines in the table.
</font><font color='#000088'>+\global\advance\multitableparskip-7pt % to keep parskip somewhat smaller
+ % than skip between lines in the table.
</font> \fi%
\ifdim\multitableparskip=0pt
\global\multitableparskip=\multitablelinespace
<font color='#880000'>-\global\advance\multitableparskip-7pt %% to keep parskip somewhat smaller
- %% than skip between lines in the table.
</font><font color='#000088'>+\global\advance\multitableparskip-7pt % to keep parskip somewhat smaller
+ % than skip between lines in the table.
</font> \fi}
<font color='#997700'>@@ -4134,11 +4289,14 @@
</font> \def\@{@}% change to @@ when we switch to @ as escape char in index files.
\def\ {\realbackslash\space }%
%
<font color='#880000'>- % Need these in case \tex is in effect and \{ is a \delimiter again.
- % But can't use \lbracecmd and \rbracecmd because texindex assumes
- % braces and backslashes are used only as delimiters.
- \let\{ = \mylbrace
- \let\} = \myrbrace
</font><font color='#000088'>+ % Need these unexpandable (because we define \tt as a dummy)
+ % definitions when @{ or @} appear in index entry text. Also, more
+ % complicated, when \tex is in effect and \{ is a \delimiter again.
+ % We can't use \lbracecmd and \rbracecmd because texindex assumes
+ % braces and backslashes are used only as delimiters. Perhaps we
+ % should define @lbrace and @rbrace commands a la @comma.
+ \def\{{{\tt\char123}}%
+ \def\}{{\tt\char125}}%
</font> %
% I don't entirely understand this, but when an index entry is
% generated from a macro call, the \endinput which \scanmacro inserts
<font color='#997700'>@@ -4191,7 +4349,7 @@
</font> \def\commondummies{%
%
% \definedummyword defines \#1 as \string\#1\space, thus effectively
<font color='#880000'>- % preventing its expansion. This is used only for control% words,
</font><font color='#000088'>+ % preventing its expansion. This is used only for control words,
</font> % not control letters, because the \space would be incorrect for
% control characters, but is needed to separate the control word
% from whatever follows.
<font color='#997700'>@@ -4210,6 +4368,7 @@
</font> \commondummiesnofonts
%
\definedummyletter\_%
<font color='#000088'>+ \definedummyletter\-%
</font> %
% Non-English letters.
\definedummyword\AA
<font color='#997700'>@@ -4246,20 +4405,24 @@
</font> \definedummyword\TeX
%
% Assorted special characters.
<font color='#000088'>+ \definedummyword\arrow
</font> \definedummyword\bullet
\definedummyword\comma
\definedummyword\copyright
\definedummyword\registeredsymbol
\definedummyword\dots
\definedummyword\enddots
<font color='#000088'>+ \definedummyword\entrybreak
</font> \definedummyword\equiv
\definedummyword\error
\definedummyword\euro
<font color='#000088'>+ \definedummyword\expansion
+ \definedummyword\geq
</font> \definedummyword\guillemetleft
\definedummyword\guillemetright
\definedummyword\guilsinglleft
\definedummyword\guilsinglright
<font color='#880000'>- \definedummyword\expansion
</font><font color='#000088'>+ \definedummyword\leq
</font> \definedummyword\minus
\definedummyword\ogonek
\definedummyword\pounds
<font color='#997700'>@@ -4316,7 +4479,9 @@
</font> \definedummyword\b
\definedummyword\i
\definedummyword\r
<font color='#000088'>+ \definedummyword\sansserif
</font> \definedummyword\sc
<font color='#000088'>+ \definedummyword\slanted
</font> \definedummyword\t
%
% Commands that take arguments.
<font color='#997700'>@@ -4325,10 +4490,12 @@
</font> \definedummyword\code
\definedummyword\command
\definedummyword\dfn
<font color='#000088'>+ \definedummyword\dmn
</font> \definedummyword\email
\definedummyword\emph
\definedummyword\env
\definedummyword\file
<font color='#000088'>+ \definedummyword\indicateurl
</font> \definedummyword\kbd
\definedummyword\key
\definedummyword\math
<font color='#997700'>@@ -4356,7 +4523,7 @@
</font> \def\definedummyaccent##1{\let##1\asis}%
% We can just ignore other control letters.
\def\definedummyletter##1{\let##1\empty}%
<font color='#880000'>- % Hopefully, all control words can become @asis.
</font><font color='#000088'>+ % All control words become @asis by default; overrides below.
</font> \let\definedummyword\definedummyaccent
%
\commondummiesnofonts
<font color='#997700'>@@ -4368,8 +4535,14 @@
</font> %
\def\ { }%
\def\@{@}%
<font color='#880000'>- % how to handle braces?
</font> \def\_{\normalunderscore}%
<font color='#000088'>+ \def\-{}% @- shouldn't affect sorting
+ %
+ % Unfortunately, texindex is not prepared to handle braces in the
+ % content at all. So for index sorting, we map @{ and @} to strings
+ % starting with |, since that ASCII character is between ASCII { and }.
+ \def\{{|a}%
+ \def\}{|b}%
</font> %
% Non-English letters.
\def\AA{AA}%
<font color='#997700'>@@ -4397,6 +4570,7 @@
</font> %
% Assorted special characters.
% (The following {} will end up in the sort string, but that's ok.)
<font color='#000088'>+ \def\arrow{->}%
</font> \def\bullet{bullet}%
\def\comma{,}%
\def\copyright{copyright}%
<font color='#997700'>@@ -4406,10 +4580,12 @@
</font> \def\error{error}%
\def\euro{euro}%
\def\expansion{==>}%
<font color='#000088'>+ \def\geq{>=}%
</font> \def\guillemetleft{<<}%
\def\guillemetright{>>}%
\def\guilsinglleft{<}%
\def\guilsinglright{>}%
<font color='#000088'>+ \def\leq{<=}%
</font> \def\minus{-}%
\def\point{.}%
\def\pounds{pounds}%
<font color='#997700'>@@ -4424,6 +4600,9 @@
</font> \def\result{=>}%
\def\textdegree{o}%
%
<font color='#000088'>+ \expandafter\ifx\csname SETtxiindexlquoteignore\endcsname\relax
+ \else \indexlquoteignore \fi
+ %
</font> % We need to get rid of all macros, leaving only the arguments (if present).
% Of course this is not nearly correct, but it is the best we can do for now.
% makeinfo does not expand macros in the argument to @deffn, which ends up
<font color='#997700'>@@ -4437,6 +4616,11 @@
</font> \macrolist
}
<font color='#000088'>+% Undocumented (for FSFS 2nd ed.): @set txiindexlquoteignore makes us
+% ignore left quotes in the sort term.
+{\catcode`\`=\active
+ \gdef\indexlquoteignore{\let`=\empty}}
+
</font> \let\indexbackslash=0 %overridden during \printindex.
\let\SETmarginindex=\relax % put index entries in margin (undocumented)?
<font color='#997700'>@@ -4694,7 +4878,6 @@
</font> % But this freezes the catcodes in the argument, and can cause problems to
% @code, which sets - active. This problem was fixed by a kludge---
% ``-'' was active throughout whole index, but this isn't really right.
<font color='#880000'>-%
</font> % The right solution is to prevent \entry from swallowing the whole text.
% --kasal, 21nov03
\def\entry{%
<font color='#997700'>@@ -4731,10 +4914,17 @@
</font> % columns.
\vskip 0pt plus1pt
%
<font color='#000088'>+ % When reading the text of entry, convert explicit line breaks
+ % from @* into spaces. The user might give these in long section
+ % titles, for instance.
+ \def\*{\unskip\space\ignorespaces}%
+ \def\entrybreak{\hfil\break}%
+ %
</font> % Swallow the left brace of the text (first parameter):
\afterassignment\doentry
\let\temp =
}
<font color='#000088'>+\def\entrybreak{\unskip\space\ignorespaces}%
</font> \def\doentry{%
\bgroup % Instead of the swallowed brace.
\noindent
<font color='#997700'>@@ -4967,7 +5157,22 @@
</font> \message{sectioning,}
% Chapters, sections, etc.
<font color='#880000'>-% \unnumberedno is an oxymoron, of course. But we count the unnumbered
</font><font color='#000088'>+% Let's start with @part.
+\outer\parseargdef\part{\partzzz{#1}}
+\def\partzzz#1{%
+ \chapoddpage
+ \null
+ \vskip.3\vsize % move it down on the page a bit
+ \begingroup
+ \noindent \titlefonts\rmisbold #1\par % the text
+ \let\lastnode=\empty % no node to associate with
+ \writetocentry{part}{#1}{}% but put it in the toc
+ \headingsoff % no headline or footline on the part page
+ \chapoddpage
+ \endgroup
+}
+
+% \unnumberedno is an oxymoron. But we count the unnumbered
</font> % sections so that we can refer to them unambiguously in the pdf
% outlines by their "section number". We avoid collisions with chapter
% numbers by starting them at 10000. (If a document ever has 10000
<font color='#997700'>@@ -5046,8 +5251,8 @@
</font> \chardef\maxseclevel = 3
%
% A numbered section within an unnumbered changes to unnumbered too.
<font color='#880000'>-% To achive this, remember the "biggest" unnum. sec. we are currently in:
-\chardef\unmlevel = \maxseclevel
</font><font color='#000088'>+% To achieve this, remember the "biggest" unnum. sec. we are currently in:
+\chardef\unnlevel = \maxseclevel
</font> %
% Trace whether the current chapter is an appendix or not:
% \chapheadtype is "N" or "A", unnumbered chapters are ignored.
<font color='#997700'>@@ -5072,8 +5277,8 @@
</font> % The heading type:
\def\headtype{#1}%
\if \headtype U%
<font color='#880000'>- \ifnum \absseclevel < \unmlevel
- \chardef\unmlevel = \absseclevel
</font><font color='#000088'>+ \ifnum \absseclevel < \unnlevel
+ \chardef\unnlevel = \absseclevel
</font> \fi
\else
% Check for appendix sections:
<font color='#997700'>@@ -5085,10 +5290,10 @@
</font> \fi\fi
\fi
% Check for numbered within unnumbered:
<font color='#880000'>- \ifnum \absseclevel > \unmlevel
</font><font color='#000088'>+ \ifnum \absseclevel > \unnlevel
</font> \def\headtype{U}%
\else
<font color='#880000'>- \chardef\unmlevel = 3
</font><font color='#000088'>+ \chardef\unnlevel = 3
</font> \fi
\fi
% Now print the heading:
<font color='#997700'>@@ -5174,7 +5379,8 @@
</font> \global\let\subsubsection = \appendixsubsubsec
}
<font color='#880000'>-\outer\parseargdef\unnumbered{\unnmhead0{#1}} % normally unnmhead0 calls unnumberedzzz
</font><font color='#000088'>+% normally unnmhead0 calls unnumberedzzz:
+\outer\parseargdef\unnumbered{\unnmhead0{#1}}
</font> \def\unnumberedzzz#1{%
\global\secno=0 \global\subsecno=0 \global\subsubsecno=0
\global\advance\unnumberedno by 1
<font color='#997700'>@@ -5218,40 +5424,47 @@
</font> \let\top\unnumbered
% Sections.
<font color='#000088'>+%<span style="background-color: #FF0000"> </span>
</font> \outer\parseargdef\numberedsec{\numhead1{#1}} % normally calls seczzz
\def\seczzz#1{%
\global\subsecno=0 \global\subsubsecno=0 \global\advance\secno by 1
\sectionheading{#1}{sec}{Ynumbered}{\the\chapno.\the\secno}%
}
<font color='#880000'>-\outer\parseargdef\appendixsection{\apphead1{#1}} % normally calls appendixsectionzzz
</font><font color='#000088'>+% normally calls appendixsectionzzz:
+\outer\parseargdef\appendixsection{\apphead1{#1}}
</font> \def\appendixsectionzzz#1{%
\global\subsecno=0 \global\subsubsecno=0 \global\advance\secno by 1
\sectionheading{#1}{sec}{Yappendix}{\appendixletter.\the\secno}%
}
\let\appendixsec\appendixsection
<font color='#880000'>-\outer\parseargdef\unnumberedsec{\unnmhead1{#1}} % normally calls unnumberedseczzz
</font><font color='#000088'>+% normally calls unnumberedseczzz:
+\outer\parseargdef\unnumberedsec{\unnmhead1{#1}}
</font> \def\unnumberedseczzz#1{%
\global\subsecno=0 \global\subsubsecno=0 \global\advance\secno by 1
\sectionheading{#1}{sec}{Ynothing}{\the\unnumberedno.\the\secno}%
}
% Subsections.
<font color='#880000'>-\outer\parseargdef\numberedsubsec{\numhead2{#1}} % normally calls numberedsubseczzz
</font><font color='#000088'>+%<span style="background-color: #FF0000"> </span>
+% normally calls numberedsubseczzz:
+\outer\parseargdef\numberedsubsec{\numhead2{#1}}
</font> \def\numberedsubseczzz#1{%
\global\subsubsecno=0 \global\advance\subsecno by 1
\sectionheading{#1}{subsec}{Ynumbered}{\the\chapno.\the\secno.\the\subsecno}%
}
<font color='#880000'>-\outer\parseargdef\appendixsubsec{\apphead2{#1}} % normally calls appendixsubseczzz
</font><font color='#000088'>+% normally calls appendixsubseczzz:
+\outer\parseargdef\appendixsubsec{\apphead2{#1}}
</font> \def\appendixsubseczzz#1{%
\global\subsubsecno=0 \global\advance\subsecno by 1
\sectionheading{#1}{subsec}{Yappendix}%
{\appendixletter.\the\secno.\the\subsecno}%
}
<font color='#880000'>-\outer\parseargdef\unnumberedsubsec{\unnmhead2{#1}} %normally calls unnumberedsubseczzz
</font><font color='#000088'>+% normally calls unnumberedsubseczzz:
+\outer\parseargdef\unnumberedsubsec{\unnmhead2{#1}}
</font> \def\unnumberedsubseczzz#1{%
\global\subsubsecno=0 \global\advance\subsecno by 1
\sectionheading{#1}{subsec}{Ynothing}%
<font color='#997700'>@@ -5259,21 +5472,25 @@
</font> }
% Subsubsections.
<font color='#880000'>-\outer\parseargdef\numberedsubsubsec{\numhead3{#1}} % normally numberedsubsubseczzz
</font><font color='#000088'>+%<span style="background-color: #FF0000"> </span>
+% normally numberedsubsubseczzz:
+\outer\parseargdef\numberedsubsubsec{\numhead3{#1}}
</font> \def\numberedsubsubseczzz#1{%
\global\advance\subsubsecno by 1
\sectionheading{#1}{subsubsec}{Ynumbered}%
{\the\chapno.\the\secno.\the\subsecno.\the\subsubsecno}%
}
<font color='#880000'>-\outer\parseargdef\appendixsubsubsec{\apphead3{#1}} % normally appendixsubsubseczzz
</font><font color='#000088'>+% normally appendixsubsubseczzz:
+\outer\parseargdef\appendixsubsubsec{\apphead3{#1}}
</font> \def\appendixsubsubseczzz#1{%
\global\advance\subsubsecno by 1
\sectionheading{#1}{subsubsec}{Yappendix}%
{\appendixletter.\the\secno.\the\subsecno.\the\subsubsecno}%
}
<font color='#880000'>-\outer\parseargdef\unnumberedsubsubsec{\unnmhead3{#1}} %normally unnumberedsubsubseczzz
</font><font color='#000088'>+% normally unnumberedsubsubseczzz:
+\outer\parseargdef\unnumberedsubsubsec{\unnmhead3{#1}}
</font> \def\unnumberedsubsubseczzz#1{%
\global\advance\subsubsecno by 1
\sectionheading{#1}{subsubsec}{Ynothing}%
<font color='#997700'>@@ -5323,14 +5540,13 @@
</font> % (including whitespace, linebreaking, etc. around it),
% given all the information in convenient, parsed form.
<font color='#880000'>-%%% Args are the skip and penalty (usually negative)
</font><font color='#000088'>+% Args are the skip and penalty (usually negative)
</font> \def\dobreak#1#2{\par\ifdim\lastskip<#1\removelastskip\penalty#2\vskip#1\fi}
<font color='#880000'>-%%% Define plain chapter starts, and page on/off switching for it
</font> % Parameter controlling skip before chapter headings (if needed)
<font color='#880000'>-
</font> \newskip\chapheadingskip
<font color='#000088'>+% Define plain chapter starts, and page on/off switching for it.
</font> \def\chapbreak{\dobreak \chapheadingskip {-4000}}
\def\chappager{\par\vfill\supereject}
% Because \domark is called before \chapoddpage, the filler page will
<font color='#997700'>@@ -5340,9 +5556,8 @@
</font> \chappager
\ifodd\pageno \else
\begingroup
<font color='#880000'>- \evenheadline={\hfil}\evenfootline={\hfil}%
- \oddheadline={\hfil}\oddfootline={\hfil}%
- \hbox to 0pt{}%
</font><font color='#000088'>+ \headingsoff
+ \null
</font> \chappager
\endgroup
\fi
<font color='#997700'>@@ -5534,6 +5749,8 @@
</font> %
\def\sectionheading#1#2#3#4{%
{%
<font color='#000088'>+ \checkenv{}% should not be in an environment.
+ %
</font> % Switch to the right set of fonts.
\csname #2fonts\endcsname \rmisbold
%
<font color='#997700'>@@ -5651,7 +5868,6 @@
</font> % This is purely so the last item on the list is a known \penalty >
% 10000. This is so \startdefun can avoid allowing breakpoints after
% section headings. Otherwise, it would insert a valid breakpoint between:
<font color='#880000'>- %
</font> % @section sec-whatever
% @deffn def-whatever
\penalty 10001
<font color='#997700'>@@ -5785,6 +6001,7 @@
</font> \def\summarycontents{%
\startcontents{\putwordShortTOC}%
%
<font color='#000088'>+ \let\partentry = \shortpartentry
</font> \let\numchapentry = \shortchapentry
\let\appentry = \shortchapentry
\let\unnchapentry = \shortunnchapentry
<font color='#997700'>@@ -5840,6 +6057,19 @@
</font> % The last argument is the page number.
% The arguments in between are the chapter number, section number, ...
<font color='#000088'>+% Parts, in the main contents. Replace the part number, which doesn't
+% exist, with an empty box. Let's hope all the numbers have the same width.
+% Also ignore the page number, which is conventionally not printed.
+\def\numeralbox{\setbox0=\hbox{8}\hbox to \wd0{\hfil}}
+\def\partentry#1#2#3#4{\dochapentry{\numeralbox\labelspace#1}{}}
+%
+% Parts, in the short toc.
+\def\shortpartentry#1#2#3#4{%
+ \penalty-300
+ \vskip.5\baselineskip plus.15\baselineskip minus.1\baselineskip
+ \shortchapentry{{\bf #1}}{\numeralbox}{}{}%
+}
+
</font> % Chapters, in the main contents.
\def\numchapentry#1#2#3#4{\dochapentry{#2\labelspace#1}{#4}}
%
<font color='#997700'>@@ -5929,9 +6159,9 @@
</font> \message{environments,}
% @foo ... @end foo.
<font color='#880000'>-% @tex ... @end tex escapes into raw Tex temporarily.
</font><font color='#000088'>+% @tex ... @end tex escapes into raw TeX temporarily.
</font> % One exception: @ is still an escape character, so that @end tex works.
<font color='#880000'>-% But \@ or @@ will get a plain tex @ character.
</font><font color='#000088'>+% But \@ or @@ will get a plain @ character.
</font>
\envdef\tex{%
\setupmarkupstyle{tex}%
<font color='#997700'>@@ -5948,6 +6178,10 @@
</font> \catcode`\'=\other
\escapechar=`\\
%
<font color='#000088'>+ % ' is active in math mode (mathcode"8000). So reset it, and all our
+ % other math active characters (just in case), to plain's definitions.
+ \mathactive
+ %
</font> \let\b=\ptexb
\let\bullet=\ptexbullet
\let\c=\ptexc
<font color='#997700'>@@ -6051,6 +6285,12 @@
</font> \normbskip=\baselineskip \normpskip=\parskip \normlskip=\lineskip
% Flag to tell @lisp, etc., not to narrow margin.
\let\nonarrowing = t%
<font color='#000088'>+ %
+ % If this cartouche directly follows a sectioning command, we need the
+ % \parskip glue (backspaced over by default) or the cartouche can
+ % collide with the section heading.
+ \ifnum\lastpenalty>10000 \vskip\parskip \fi
+ %
</font> \vbox\bgroup
\baselineskip=0pt\parskip=0pt\lineskip=0pt
\carttop
<font color='#997700'>@@ -6064,7 +6304,7 @@
</font> \lineskip=\normlskip
\parskip=\normpskip
\vskip -\parskip
<font color='#880000'>- \comment % For explanation, see the end of \def\group.
</font><font color='#000088'>+ \comment % For explanation, see the end of def\group.
</font> }
\def\Ecartouche{%
\ifhmode\par\fi
<font color='#997700'>@@ -6150,41 +6390,42 @@
</font> }
% We often define two environments, @foo and @smallfoo.
<font color='#880000'>-% Let's do it by one command:
-\def\makedispenv #1#2{
- \expandafter\envdef\csname#1\endcsname {\setnormaldispenv #2}
- \expandafter\envdef\csname small#1\endcsname {\setsmalldispenv #2}
</font><font color='#000088'>+% Let's do it in one command. #1 is the env name, #2 the definition.
+\def\makedispenvdef#1#2{%
+ \expandafter\envdef\csname#1\endcsname {\setnormaldispenv #2}%
+ \expandafter\envdef\csname small#1\endcsname {\setsmalldispenv #2}%
</font> \expandafter\let\csname E#1\endcsname \afterenvbreak
\expandafter\let\csname Esmall#1\endcsname \afterenvbreak
}
<font color='#880000'>-% Define two synonyms:
-\def\maketwodispenvs #1#2#3{
- \makedispenv{#1}{#3}
- \makedispenv{#2}{#3}
</font><font color='#000088'>+% Define two environment synonyms (#1 and #2) for an environment.
+\def\maketwodispenvdef#1#2#3{%
+ \makedispenvdef{#1}{#3}%
+ \makedispenvdef{#2}{#3}%
</font> }
<font color='#880000'>-
-% @lisp: indented, narrowed, typewriter font; @example: same as @lisp.
</font><font color='#000088'>+%
+% @lisp: indented, narrowed, typewriter font;
+% @example: same as @lisp.
</font> %
% @smallexample and @smalllisp: use smaller fonts.
% Originally contributed by Pavel@xerox.
%
<font color='#880000'>-\maketwodispenvs {lisp}{example}{%
</font><font color='#000088'>+\maketwodispenvdef{lisp}{example}{%
</font> \nonfillstart
\tt\setupmarkupstyle{example}%
\let\kbdfont = \kbdexamplefont % Allow @kbd to do something special.
<font color='#880000'>- \gobble % eat return
</font><font color='#000088'>+ \gobble % eat return
</font> }
% @display/@smalldisplay: same as @lisp except keep current font.
%
<font color='#880000'>-\makedispenv {display}{%
</font><font color='#000088'>+\makedispenvdef{display}{%
</font> \nonfillstart
\gobble
}
% @format/@smallformat: same as @display except don't narrow margins.
%
<font color='#880000'>-\makedispenv{format}{%
</font><font color='#000088'>+\makedispenvdef{format}{%
</font> \let\nonarrowing = t%
\nonfillstart
\gobble
<font color='#997700'>@@ -6203,7 +6444,7 @@
</font> \envdef\flushright{%
\let\nonarrowing = t%
\nonfillstart
<font color='#880000'>- \advance\leftskip by 0pt plus 1fill
</font><font color='#000088'>+ \advance\leftskip by 0pt plus 1fill\relax
</font> \gobble
}
\let\Eflushright = \afterenvbreak
<font color='#997700'>@@ -6238,6 +6479,8 @@
</font> % we're doing normal filling. So, when using \aboveenvbreak and
% \afterenvbreak, temporarily make \parskip 0.
%
<font color='#000088'>+\makedispenvdef{quotation}{\quotationstart}
+%
</font> \def\quotationstart{%
{\parskip=0pt \aboveenvbreak}% because \aboveenvbreak inserts \parskip
\parindent=0pt
<font color='#997700'>@@ -6253,28 +6496,18 @@
</font> \parsearg\quotationlabel
}
<font color='#880000'>-\envdef\quotation{%
- \setnormaldispenv
- \quotationstart
-}
-
-\envdef\smallquotation{%
- \setsmalldispenv
- \quotationstart
-}
-\let\Esmallquotation = \Equotation
-
</font> % We have retained a nonzero parskip for the environment, since we're
% doing normal filling.
%
\def\Equotation{%
\par
<font color='#880000'>- \ifx\quotationauthor\undefined\else
</font><font color='#000088'>+ \ifx\quotationauthor\thisisundefined\else
</font> % indent a bit.
\leftline{\kern 2\leftskip \sl ---\quotationauthor}%
\fi
{\parskip=0pt \afterenvbreak}%
}
<font color='#000088'>+\def\Esmallquotation{\Equotation}
</font>
% If we're given an argument, typeset it in bold with a colon after.
\def\quotationlabel#1{%
<font color='#997700'>@@ -6331,21 +6564,28 @@
</font>
% Setup for the @verbatim environment
%
<font color='#880000'>-% Real tab expansion
</font><font color='#000088'>+% Real tab expansion.
</font> \newdimen\tabw \setbox0=\hbox{\tt\space} \tabw=8\wd0 % tab amount
%
<font color='#880000'>-\def\starttabbox{\setbox0=\hbox\bgroup}
</font><font color='#000088'>+% We typeset each line of the verbatim in an \hbox, so we can handle
+% tabs. The \global is in case the verbatim line starts with an accent,
+% or some other command that starts with a begin-group. Otherwise, the
+% entire \verbbox would disappear at the corresponding end-group, before
+% it is typeset. Meanwhile, we can't have nested verbatim commands
+% (can we?), so the \global won't be overwriting itself.
+\newbox\verbbox
+\def\starttabbox{\global\setbox\verbbox=\hbox\bgroup}
</font> %
\begingroup
\catcode`\^^I=\active
\gdef\tabexpand{%
\catcode`\^^I=\active
\def^^I{\leavevmode\egroup
<font color='#880000'>- \dimen0=\wd0 % the width so far, or since the previous tab
- \divide\dimen0 by\tabw
- \multiply\dimen0 by\tabw % compute previous multiple of \tabw
- \advance\dimen0 by\tabw % advance to next multiple of \tabw
- \wd0=\dimen0 \box0 \starttabbox
</font><font color='#000088'>+ \dimen\verbbox=\wd\verbbox % the width so far, or since the previous tab
+ \divide\dimen\verbbox by\tabw
+ \multiply\dimen\verbbox by\tabw % compute previous multiple of \tabw
+ \advance\dimen\verbbox by\tabw % advance to next multiple of \tabw
+ \wd\verbbox=\dimen\verbbox \box\verbbox \starttabbox
</font> }%
}
\endgroup
<font color='#997700'>@@ -6354,15 +6594,16 @@
</font> \def\setupverbatim{%
\let\nonarrowing = t%
\nonfillstart
<font color='#880000'>- % Easiest (and conventionally used) font for verbatim
- \tt
- \def\par{\leavevmode\egroup\box0\endgraf}%
</font><font color='#000088'>+ \tt % easiest (and conventionally used) font for verbatim
+ % The \leavevmode here is for blank lines. Otherwise, we would
+ % never \starttabox and the \egroup would end verbatim mode.
+ \def\par{\leavevmode\egroup\box\verbbox\endgraf}%
</font> \tabexpand
\setupmarkupstyle{verbatim}%
% Respect line breaks,
% print special symbols as themselves, and
<font color='#880000'>- % make each space count
- % must do in this order:
</font><font color='#000088'>+ % make each space count.
+ % Must do in this order:
</font> \obeylines \uncatcodespecials \sepspaces
\everypar{\starttabbox}%
}
<font color='#997700'>@@ -6419,6 +6660,7 @@
</font> \makevalueexpandable
\setupverbatim
\indexnofonts % Allow `@@' and other weird things in file names.
<font color='#000088'>+ \wlog{texinfo.tex: doing @verbatiminclude of #1^^J}%
</font> \input #1
\afterenvbreak
}%
<font color='#997700'>@@ -6468,7 +6710,7 @@
</font> % commands also insert a nobreak penalty, and we don't want to allow
% a break between a section heading and a defun.
%
<font color='#880000'>- % As a minor refinement, we avoid "club" headers by signalling
</font><font color='#000088'>+ % As a further refinement, we avoid "club" headers by signalling
</font> % with penalty of 10003 after the very first @deffn in the
% sequence (see above), and penalty of 10002 after any following
% @def command.
<font color='#997700'>@@ -6505,7 +6747,7 @@
</font> #1#2 \endheader
% common ending:
\interlinepenalty = 10000
<font color='#880000'>- \advance\rightskip by 0pt plus 1fil
</font><font color='#000088'>+ \advance\rightskip by 0pt plus 1fil\relax
</font> \endgraf
\nobreak\vskip -\parskip
\penalty\defunpenalty % signal to \startdefun and \dodefunx
<font color='#997700'>@@ -6535,13 +6777,36 @@
</font> \def\domakedefun#1#2#3{%
\envdef#1{%
\startdefun
<font color='#000088'>+ \doingtypefnfalse % distinguish typed functions from all else
</font> \parseargusing\activeparens{\printdefunline#3}%
}%
\def#2{\dodefunx#1}%
\def#3%
}
<font color='#880000'>-%%% Untyped functions:
</font><font color='#000088'>+\newif\ifdoingtypefn % doing typed function?
+\newif\ifrettypeownline % typeset return type on its own line?
+
+% @deftypefnnewline on|off says whether the return type of typed functions
+% are printed on their own line. This affects @deftypefn, @deftypefun,
+% @deftypeop, and @deftypemethod.
+%<span style="background-color: #FF0000"> </span>
+\parseargdef\deftypefnnewline{%
+ \def\temp{#1}%
+ \ifx\temp\onword
+ \expandafter\let\csname SETtxideftypefnnl\endcsname
+ = \empty
+ \else\ifx\temp\offword
+ \expandafter\let\csname SETtxideftypefnnl\endcsname
+ = \relax
+ \else
+ \errhelp = \EMsimple
+ \errmessage{Unknown @txideftypefnnl value `\temp',
+ must be on|off}%
+ \fi\fi
+}
+
+% Untyped functions:
</font>
% @deffn category name args
\makedefun{deffn}{\deffngeneral{}}
<font color='#997700'>@@ -6560,7 +6825,7 @@
</font> \defname{#2}{}{#3}\magicamp\defunargs{#4\unskip}%
}
<font color='#880000'>-%%% Typed functions:
</font><font color='#000088'>+% Typed functions:
</font>
% @deftypefn category type name args
\makedefun{deftypefn}{\deftypefngeneral{}}
<font color='#997700'>@@ -6575,10 +6840,11 @@
</font> %
\def\deftypefngeneral#1#2 #3 #4 #5\endheader{%
\dosubind{fn}{\code{#4}}{#1}%
<font color='#000088'>+ \doingtypefntrue
</font> \defname{#2}{#3}{#4}\defunargs{#5\unskip}%
}
<font color='#880000'>-%%% Typed variables:
</font><font color='#000088'>+% Typed variables:
</font>
% @deftypevr category type var args
\makedefun{deftypevr}{\deftypecvgeneral{}}
<font color='#997700'>@@ -6596,7 +6862,7 @@
</font> \defname{#2}{#3}{#4}\defunargs{#5\unskip}%
}
<font color='#880000'>-%%% Untyped variables:
</font><font color='#000088'>+% Untyped variables:
</font>
% @defvr category var args
\makedefun{defvr}#1 {\deftypevrheader{#1} {} }
<font color='#997700'>@@ -6607,7 +6873,8 @@
</font> % \defcvof {category of}class var args
\def\defcvof#1#2 {\deftypecvof{#1}#2 {} }
<font color='#880000'>-%%% Type:
</font><font color='#000088'>+% Types:
+
</font> % @deftp category name args
\makedefun{deftp}#1 #2 #3\endheader{%
\doind{tp}{\code{#2}}%
<font color='#997700'>@@ -6635,25 +6902,49 @@
</font> % We are followed by (but not passed) the arguments, if any.
%
\def\defname#1#2#3{%
<font color='#000088'>+ \par
</font> % Get the values of \leftskip and \rightskip as they were outside the @def...
\advance\leftskip by -\defbodyindent
%
<font color='#880000'>- % How we'll format the type name. Putting it in brackets helps
</font><font color='#000088'>+ % Determine if we are typesetting the return type of a typed function
+ % on a line by itself.
+ \rettypeownlinefalse
+ \ifdoingtypefn % doing a typed function specifically?
+ % then check user option for putting return type on its own line:
+ \expandafter\ifx\csname SETtxideftypefnnl\endcsname\relax \else
+ \rettypeownlinetrue
+ \fi
+ \fi
+ %
+ % How we'll format the category name. Putting it in brackets helps
</font> % distinguish it from the body text that may end up on the next line
% just below it.
\def\temp{#1}%
\setbox0=\hbox{\kern\deflastargmargin \ifx\temp\empty\else [\rm\temp]\fi}
%
<font color='#880000'>- % Figure out line sizes for the paragraph shape.
</font><font color='#000088'>+ % Figure out line sizes for the paragraph shape. We'll always have at
+ % least two.
+ \tempnum = 2
+ %
</font> % The first line needs space for \box0; but if \rightskip is nonzero,
% we need only space for the part of \box0 which exceeds it:
\dimen0=\hsize \advance\dimen0 by -\wd0 \advance\dimen0 by \rightskip
<font color='#000088'>+ %
+ % If doing a return type on its own line, we'll have another line.
+ \ifrettypeownline
+ \advance\tempnum by 1
+ \def\maybeshapeline{0in \hsize}%
+ \else
+ \def\maybeshapeline{}%
+ \fi
+ %
</font> % The continuations:
\dimen2=\hsize \advance\dimen2 by -\defargsindent
<font color='#880000'>- % (plain.tex says that \dimen1 should be used only as global.)
- \parshape 2 0in \dimen0 \defargsindent \dimen2
</font> %
<font color='#880000'>- % Put the type name to the right margin.
</font><font color='#000088'>+ % The final paragraph shape:
+ \parshape \tempnum 0in \dimen0 \maybeshapeline \defargsindent \dimen2
+ %
+ % Put the category name at the right margin.
</font> \noindent
\hbox to 0pt{%
\hfil\box0 \kern-\hsize
<font color='#997700'>@@ -6675,8 +6966,16 @@
</font> % . this still does not fix the ?` and !` ligatures, but so far no
% one has made identifiers using them :).
\df \tt
<font color='#880000'>- \def\temp{#2}% return value type
- \ifx\temp\empty\else \tclose{\temp} \fi
</font><font color='#000088'>+ \def\temp{#2}% text of the return type
+ \ifx\temp\empty\else
+ \tclose{\temp}% typeset the return type
+ \ifrettypeownline
+ % put return type on its own line; prohibit line break following:
+ \hfil\vadjust{\nobreak}\break<span style="background-color: #FF0000"> </span>
+ \else
+ \space % type on same line, so just followed by a space
+ \fi
+ \fi % no return type
</font> #3% output function name
}%
{\rm\enskip}% hskip 0.5 em of \tenrm
<font color='#997700'>@@ -6794,7 +7093,7 @@
</font>
% To do this right we need a feature of e-TeX, \scantokens,
% which we arrange to emulate with a temporary file in ordinary TeX.
<font color='#880000'>-\ifx\eTeXversion\undefined
</font><font color='#000088'>+\ifx\eTeXversion\thisisundefined
</font> \newwrite\macscribble
\def\scantokens#1{%
\toks0={#1}%
<font color='#997700'>@@ -6805,25 +7104,30 @@
</font> }
\fi
<font color='#880000'>-\def\scanmacro#1{%
- \begingroup
- \newlinechar`\^^M
- \let\xeatspaces\eatspaces
- % Undo catcode changes of \startcontents and \doprintindex
- % When called from @insertcopying or (short)caption, we need active
- % backslash to get it printed correctly. Previously, we had
- % \catcode`\\=\other instead. We'll see whether a problem appears
- % with macro expansion. --kasal, 19aug04
- \catcode`\@=0 \catcode`\\=\active \escapechar=`\@
- % ... and \example
- \spaceisspace
- %
- % Append \endinput to make sure that TeX does not see the ending newline.
- % I've verified that it is necessary both for e-TeX and for ordinary TeX
- % --kasal, 29nov03
- \scantokens{#1\endinput}%
- \endgroup
-}
</font><font color='#000088'>+\def\scanmacro#1{\begingroup
+ \newlinechar`\^^M
+ \let\xeatspaces\eatspaces
+ %
+ % Undo catcode changes of \startcontents and \doprintindex
+ % When called from @insertcopying or (short)caption, we need active
+ % backslash to get it printed correctly. Previously, we had
+ % \catcode`\\=\other instead. We'll see whether a problem appears
+ % with macro expansion. --kasal, 19aug04
+ \catcode`\@=0 \catcode`\\=\active \escapechar=`\@
+ %
+ % ... and for \example:
+ \spaceisspace
+ %
+ % The \empty here causes a following catcode 5 newline to be eaten as
+ % part of reading whitespace after a control sequence. It does not
+ % eat a catcode 13 newline. There's no good way to handle the two
+ % cases (untried: maybe e-TeX's \everyeof could help, though plain TeX
+ % would then have different behavior). See the Macro Details node in
+ % the manual for the workaround we recommend for macros and
+ % line-oriented commands.
+ %<span style="background-color: #FF0000"> </span>
+ \scantokens{#1\empty}%
+\endgroup}
</font>
\def\scanexp#1{%
\edef\temp{\noexpand\scanmacro{#1}}%
<font color='#997700'>@@ -6877,17 +7181,18 @@
</font>
% Macro bodies are absorbed as an argument in a context where
% all characters are catcode 10, 11 or 12, except \ which is active
<font color='#880000'>-% (as in normal texinfo). It is necessary to change the definition of \.
-
</font><font color='#000088'>+% (as in normal texinfo). It is necessary to change the definition of \
+% to recognize macro arguments; this is the job of \mbodybackslash.
+%
</font> % Non-ASCII encodings make 8-bit characters active, so un-activate
% them to avoid their expansion. Must do this non-globally, to
% confine the change to the current group.
<font color='#880000'>-
</font><font color='#000088'>+%
</font> % It's necessary to have hard CRs when the macro is executed. This is
<font color='#880000'>-% done by making ^^M (\endlinechar) catcode 12 when reading the macro
</font><font color='#000088'>+% done by making ^^M (\endlinechar) catcode 12 when reading the macro
</font> % body, and then making it the \newlinechar in \scanmacro.
<font color='#880000'>-
-\def\scanctxt{%
</font><font color='#000088'>+%
+\def\scanctxt{% used as subroutine
</font> \catcode`\"=\other
\catcode`\+=\other
\catcode`\<=\other
<font color='#997700'>@@ -6900,13 +7205,13 @@
</font> \ifx\declaredencoding\ascii \else \setnonasciicharscatcodenonglobal\other \fi
}
<font color='#880000'>-\def\scanargctxt{%
</font><font color='#000088'>+\def\scanargctxt{% used for copying and captions, not macros.
</font> \scanctxt
\catcode`\\=\other
\catcode`\^^M=\other
}
<font color='#880000'>-\def\macrobodyctxt{%
</font><font color='#000088'>+\def\macrobodyctxt{% used for @macro definitions
</font> \scanctxt
\catcode`\{=\other
\catcode`\}=\other
<font color='#997700'>@@ -6914,32 +7219,56 @@
</font> \usembodybackslash
}
<font color='#880000'>-\def\macroargctxt{%
</font><font color='#000088'>+\def\macroargctxt{% used when scanning invocations
</font> \scanctxt
<font color='#880000'>- \catcode`\\=\other
</font><font color='#000088'>+ \catcode`\\=0
</font> }
<font color='#000088'>+% why catcode 0 for \ in the above? To recognize \\ \{ \} as "escapes"
+% for the single characters \ { }. Thus, we end up with the "commands"
+% that would be written @\ @{ @} in a Texinfo document.
+%<span style="background-color: #FF0000"> </span>
+% We already have @{ and @}. For @\, we define it here, and only for
+% this purpose, to produce a typewriter backslash (so, the @\ that we
+% define for @math can't be used with @macro calls):
+%
+\def\\{\normalbackslash}%
+%<span style="background-color: #FF0000"> </span>
+% We would like to do this for \, too, since that is what makeinfo does.
+% But it is not possible, because Texinfo already has a command @, for a
+% cedilla accent. Documents must use @comma{} instead.
+%
+% \anythingelse will almost certainly be an error of some kind.
+
</font>
% \mbodybackslash is the definition of \ in @macro bodies.
% It maps \foo\ => \csname macarg.foo\endcsname => #N
% where N is the macro parameter number.
% We define \csname macarg.\endcsname to be \realbackslash, so
% \\ in macro replacement text gets you a backslash.
<font color='#880000'>-
</font><font color='#000088'>+%
</font> {\catcode`@=0 @catcode`@\=@active
@gdef@usembodybackslash{@let\=@mbodybackslash}
@gdef@mbodybackslash#1\{@csname macarg.#1@endcsname}
}
\expandafter\def\csname macarg.\endcsname{\realbackslash}
<font color='#000088'>+\def\margbackslash#1{\char`\#1 }
+
</font> \def\macro{\recursivefalse\parsearg\macroxxx}
\def\rmacro{\recursivetrue\parsearg\macroxxx}
\def\macroxxx#1{%
<font color='#880000'>- \getargs{#1}% now \macname is the macname and \argl the arglist
</font><font color='#000088'>+ \getargs{#1}% now \macname is the macname and \argl the arglist
</font> \ifx\argl\empty % no arguments
<font color='#880000'>- \paramno=0%
</font><font color='#000088'>+ \paramno=0\relax
</font> \else
\expandafter\parsemargdef \argl;%
<font color='#000088'>+ \if\paramno>256\relax
+ \ifx\eTeXversion\thisisundefined
+ \errhelp = \EMsimple
+ \errmessage{You need eTeX to compile a file with macros with more than 256 arguments}
+ \fi
+ \fi
</font> \fi
\if1\csname ismacro.\the\macname\endcsname
\message{Warning: redefining \the\macname}%
<font color='#997700'>@@ -6986,46 +7315,269 @@
</font> % an opening brace, and that opening brace is not consumed.
\def\getargs#1{\getargsxxx#1{}}
\def\getargsxxx#1#{\getmacname #1 \relax\getmacargs}
<font color='#880000'>-\def\getmacname #1 #2\relax{\macname={#1}}
</font><font color='#000088'>+\def\getmacname#1 #2\relax{\macname={#1}}
</font> \def\getmacargs#1{\def\argl{#1}}
<font color='#000088'>+% For macro processing make @ a letter so that we can make Texinfo private macro names.
+\edef\texiatcatcode{\the\catcode`\@}
+\catcode `@=11\relax
+
</font> % Parse the optional {params} list. Set up \paramno and \paramlist
<font color='#880000'>-% so \defmacro knows what to do. Define \macarg.blah for each blah
-% in the params list, to be ##N where N is the position in that list.
</font><font color='#000088'>+% so \defmacro knows what to do. Define \macarg.BLAH for each BLAH
+% in the params list to some hook where the argument si to be expanded. If
+% there are less than 10 arguments that hook is to be replaced by ##N where N
+% is the position in that list, that is to say the macro arguments are to be
+% defined `a la TeX in the macro body.<span style="background-color: #FF0000"> </span>
+%
</font> % That gets used by \mbodybackslash (above).
<font color='#880000'>-
</font><font color='#000088'>+%
</font> % We need to get `macro parameter char #' into several definitions.
<font color='#880000'>-% The technique used is stolen from LaTeX: let \hash be something
</font><font color='#000088'>+% The technique used is stolen from LaTeX: let \hash be something
</font> % unexpandable, insert that wherever you need a #, and then redefine
% it to # just before using the token list produced.
%
% The same technique is used to protect \eatspaces till just before
% the macro is used.
<font color='#880000'>-
-\def\parsemargdef#1;{\paramno=0\def\paramlist{}%
- \let\hash\relax\let\xeatspaces\relax\parsemargdefxxx#1,;,}
</font><font color='#000088'>+%
+% If there are 10 or more arguments, a different technique is used, where the
+% hook remains in the body, and when macro is to be expanded the body is
+% processed again to replace the arguments.
+%
+% In that case, the hook is \the\toks N-1, and we simply set \toks N-1 to the
+% argument N value and then \edef the body (nothing else will expand because of
+% the catcode regime underwhich the body was input).
+%
+% If you compile with TeX (not eTeX), and you have macros with 10 or more
+% arguments, you need that no macro has more than 256 arguments, otherwise an
+% error is produced.
+\def\parsemargdef#1;{%
+ \paramno=0\def\paramlist{}%
+ \let\hash\relax
+ \let\xeatspaces\relax
+ \parsemargdefxxx#1,;,%
+ % In case that there are 10 or more arguments we parse again the arguments
+ % list to set new definitions for the \macarg.BLAH macros corresponding to
+ % each BLAH argument. It was anyhow needed to parse already once this list
+ % in order to count the arguments, and as macros with at most 9 arguments
+ % are by far more frequent than macro with 10 or more arguments, defining
+ % twice the \macarg.BLAH macros does not cost too much processing power.
+ \ifnum\paramno<10\relax\else
+ \paramno0\relax
+ \parsemmanyargdef@@#1,;,% 10 or more arguments
+ \fi
+}
</font> \def\parsemargdefxxx#1,{%
\if#1;\let\next=\relax
\else \let\next=\parsemargdefxxx
<font color='#880000'>- \advance\paramno by 1%
</font><font color='#000088'>+ \advance\paramno by 1
</font> \expandafter\edef\csname macarg.\eatspaces{#1}\endcsname
{\xeatspaces{\hash\the\paramno}}%
\edef\paramlist{\paramlist\hash\the\paramno,}%
\fi\next}
<font color='#000088'>+\def\parsemmanyargdef@@#1,{%
+ \if#1;\let\next=\relax
+ \else<span style="background-color: #FF0000"> </span>
+ \let\next=\parsemmanyargdef@@
+ \edef\tempb{\eatspaces{#1}}%
+ \expandafter\def\expandafter\tempa
+ \expandafter{\csname macarg.\tempb\endcsname}%
+ % Note that we need some extra \noexpand\noexpand, this is because we
+ % don't want \the to be expanded in the \parsermacbody as it uses an
+ % \xdef .
+ \expandafter\edef\tempa
+ {\noexpand\noexpand\noexpand\the\toks\the\paramno}%
+ \advance\paramno by 1\relax
+ \fi\next}
+
</font> % These two commands read recursive and nonrecursive macro bodies.
% (They're different since rec and nonrec macros end differently.)
<font color='#000088'>+%
</font>
<font color='#000088'>+\catcode `\@\texiatcatcode
</font> \long\def\parsemacbody#1@end macro%
{\xdef\temp{\eatcr{#1}}\endgroup\defmacro}%
\long\def\parsermacbody#1@end rmacro%
{\xdef\temp{\eatcr{#1}}\endgroup\defmacro}%
<font color='#000088'>+\catcode `\@=11\relax
+
+\let\endargs@\relax
+\let\nil@\relax
+\def\nilm@{\nil@}%
+\long\def\nillm@{\nil@}%
+
+% This macro is expanded during the Texinfo macro expansion, not during its
+% definition. It gets all the arguments values and assigns them to macros
+% macarg.ARGNAME
+%
+% #1 is the macro name
+% #2 is the list of argument names
+% #3 is the list of argument values
+\def\getargvals@#1#2#3{%
+ \def\macargdeflist@{}%
+ \def\saveparamlist@{#2}% Need to keep a copy for parameter expansion.
+ \def\paramlist{#2,\nil@}%
+ \def\macroname{#1}%
+ \begingroup
+ \macroargctxt
+ \def\argvaluelist{#3,\nil@}%
+ \def\@tempa{#3}%
+ \ifx\@tempa\empty
+ \setemptyargvalues@
+ \else
+ \getargvals@@
+ \fi
+}
</font>
<font color='#880000'>-% This defines the macro itself. There are six cases: recursive and
-% nonrecursive macros of zero, one, and many arguments.
</font><font color='#000088'>+%<span style="background-color: #FF0000"> </span>
+\def\getargvals@@{%
+ \ifx\paramlist\nilm@
+ % Some sanity check needed here that \argvaluelist is also empty.
+ \ifx\argvaluelist\nillm@
+ \else
+ \errhelp = \EMsimple
+ \errmessage{Too many arguments in macro `\macroname'!}%
+ \fi
+ \let\next\macargexpandinbody@
+ \else
+ \ifx\argvaluelist\nillm@
+ % No more arguments values passed to macro. Set remaining named-arg
+ % macros to empty.
+ \let\next\setemptyargvalues@
+ \else
+ % pop current arg name into \@tempb
+ \def\@tempa##1{\pop@{\@tempb}{\paramlist}##1\endargs@}%
+ \expandafter\@tempa\expandafter{\paramlist}%
+ % pop current argument value into \@tempc
+ \def\@tempa##1{\longpop@{\@tempc}{\argvaluelist}##1\endargs@}%
+ \expandafter\@tempa\expandafter{\argvaluelist}%
+ % Here \@tempb is the current arg name and \@tempc is the current arg value.
+ % First place the new argument macro definition into \@tempd
+ \expandafter\macname\expandafter{\@tempc}%
+ \expandafter\let\csname macarg.\@tempb\endcsname\relax
+ \expandafter\def\expandafter\@tempe\expandafter{%
+ \csname macarg.\@tempb\endcsname}%
+ \edef\@tempd{\long\def\@tempe{\the\macname}}%
+ \push@\@tempd\macargdeflist@
+ \let\next\getargvals@@
+ \fi
+ \fi
+ \next
+}
+
+\def\push@#1#2{%
+ \expandafter\expandafter\expandafter\def
+ \expandafter\expandafter\expandafter#2%
+ \expandafter\expandafter\expandafter{%
+ \expandafter#1#2}%
+}
+
+% Replace arguments by their values in the macro body, and place the result
+% in macro \@tempa
+\def\macvalstoargs@{%
+ % To do this we use the property that token registers that are \the'ed
+ % within an \edef expand only once. So we are going to place all argument
+ % values into respective token registers.
+ %
+ % First we save the token context, and initialize argument numbering.
+ \begingroup
+ \paramno0\relax
+ % Then, for each argument number #N, we place the corresponding argument
+ % value into a new token list register \toks#N
+ \expandafter\putargsintokens@\saveparamlist@,;,%
+ % Then, we expand the body so that argument are replaced by their
+ % values. The trick for values not to be expanded themselves is that they
+ % are within tokens and that tokens expand only once in an \edef .
+ \edef\@tempc{\csname mac.\macroname .body\endcsname}%
+ % Now we restore the token stack pointer to free the token list registers
+ % which we have used, but we make sure that expanded body is saved after
+ % group.
+ \expandafter
+ \endgroup
+ \expandafter\def\expandafter\@tempa\expandafter{\@tempc}%
+ }
+
+\def\macargexpandinbody@{%<span style="background-color: #FF0000"> </span>
+ %% Define the named-macro outside of this group and then close this group.<span style="background-color: #FF0000"> </span>
+ \expandafter
+ \endgroup
+ \macargdeflist@
+ % First the replace in body the macro arguments by their values, the result
+ % is in \@tempa .
+ \macvalstoargs@
+ % Then we point at the \norecurse or \gobble (for recursive) macro value
+ % with \@tempb .
+ \expandafter\let\expandafter\@tempb\csname mac.\macroname .recurse\endcsname
+ % Depending on whether it is recursive or not, we need some tailing
+ % \egroup .
+ \ifx\@tempb\gobble
+ \let\@tempc\relax
+ \else
+ \let\@tempc\egroup
+ \fi
+ % And now we do the real job:
+ \edef\@tempd{\noexpand\@tempb{\macroname}\noexpand\scanmacro{\@tempa}\@tempc}%
+ \@tempd
+}
+
+\def\putargsintokens@#1,{%
+ \if#1;\let\next\relax
+ \else
+ \let\next\putargsintokens@
+ % First we allocate the new token list register, and give it a temporary
+ % alias \@tempb .
+ \toksdef\@tempb\the\paramno
+ % Then we place the argument value into that token list register.
+ \expandafter\let\expandafter\@tempa\csname macarg.#1\endcsname
+ \expandafter\@tempb\expandafter{\@tempa}%
+ \advance\paramno by 1\relax
+ \fi
+ \next
+}
+
+% Save the token stack pointer into macro #1
+\def\texisavetoksstackpoint#1{\edef#1{\the\@cclvi}}
+% Restore the token stack pointer from number in macro #1
+\def\texirestoretoksstackpoint#1{\expandafter\mathchardef\expandafter\@cclvi#1\relax}
+% newtoks that can be used non \outer .
+\def\texinonouternewtoks{\alloc@ 5\toks \toksdef \@cclvi}
+
+% Tailing missing arguments are set to empty
+\def\setemptyargvalues@{%
+ \ifx\paramlist\nilm@
+ \let\next\macargexpandinbody@
+ \else
+ \expandafter\setemptyargvaluesparser@\paramlist\endargs@
+ \let\next\setemptyargvalues@
+ \fi
+ \next
+}
+
+\def\setemptyargvaluesparser@#1,#2\endargs@{%
+ \expandafter\def\expandafter\@tempa\expandafter{%
+ \expandafter\def\csname macarg.#1\endcsname{}}%
+ \push@\@tempa\macargdeflist@
+ \def\paramlist{#2}%
+}
+
+% #1 is the element target macro
+% #2 is the list macro
+% #3,#4\endargs@ is the list value
+\def\pop@#1#2#3,#4\endargs@{%
+ \def#1{#3}%
+ \def#2{#4}%
+}
+\long\def\longpop@#1#2#3,#4\endargs@{%
+ \long\def#1{#3}%
+ \long\def#2{#4}%
+}
+
+% This defines a Texinfo @macro. There are eight cases: recursive and
+% nonrecursive macros of zero, one, up to nine, and many arguments.
</font> % Much magic with \expandafter here.
% \xdef is used so that macro definitions will survive the file
% they're defined in; @include reads the file inside a group.
<font color='#000088'>+%
</font> \def\defmacro{%
\let\hash=##% convert placeholders to macro parameter chars
\ifrecursive
<font color='#997700'>@@ -7040,17 +7592,25 @@
</font> \expandafter\noexpand\csname\the\macname xxx\endcsname}%
\expandafter\xdef\csname\the\macname xxx\endcsname##1{%
\egroup\noexpand\scanmacro{\temp}}%
<font color='#880000'>- \else % many
- \expandafter\xdef\csname\the\macname\endcsname{%
- \bgroup\noexpand\macroargctxt
- \noexpand\csname\the\macname xx\endcsname}%
- \expandafter\xdef\csname\the\macname xx\endcsname##1{%
- \expandafter\noexpand\csname\the\macname xxx\endcsname ##1,}%
- \expandafter\expandafter
- \expandafter\xdef
- \expandafter\expandafter
- \csname\the\macname xxx\endcsname
- \paramlist{\egroup\noexpand\scanmacro{\temp}}%
</font><font color='#000088'>+ \else
+ \ifnum\paramno<10\relax % at most 9
+ \expandafter\xdef\csname\the\macname\endcsname{%
+ \bgroup\noexpand\macroargctxt
+ \noexpand\csname\the\macname xx\endcsname}%
+ \expandafter\xdef\csname\the\macname xx\endcsname##1{%
+ \expandafter\noexpand\csname\the\macname xxx\endcsname ##1,}%
+ \expandafter\expandafter
+ \expandafter\xdef
+ \expandafter\expandafter
+ \csname\the\macname xxx\endcsname
+ \paramlist{\egroup\noexpand\scanmacro{\temp}}%
+ \else % 10 or more
+ \expandafter\xdef\csname\the\macname\endcsname{%
+ \noexpand\getargvals@{\the\macname}{\argl}%
+ }%<span style="background-color: #FF0000"> </span>
+ \global\expandafter\let\csname mac.\the\macname .body\endcsname\temp
+ \global\expandafter\let\csname mac.\the\macname .recurse\endcsname\gobble
+ \fi
</font> \fi
\else
\ifcase\paramno
<font color='#997700'>@@ -7067,29 +7627,40 @@
</font> \egroup
\noexpand\norecurse{\the\macname}%
\noexpand\scanmacro{\temp}\egroup}%
<font color='#880000'>- \else % many
- \expandafter\xdef\csname\the\macname\endcsname{%
- \bgroup\noexpand\macroargctxt
- \expandafter\noexpand\csname\the\macname xx\endcsname}%
- \expandafter\xdef\csname\the\macname xx\endcsname##1{%
- \expandafter\noexpand\csname\the\macname xxx\endcsname ##1,}%
- \expandafter\expandafter
- \expandafter\xdef
- \expandafter\expandafter
- \csname\the\macname xxx\endcsname
- \paramlist{%
- \egroup
- \noexpand\norecurse{\the\macname}%
- \noexpand\scanmacro{\temp}\egroup}%
</font><font color='#000088'>+ \else % at most 9
+ \ifnum\paramno<10\relax
+ \expandafter\xdef\csname\the\macname\endcsname{%
+ \bgroup\noexpand\macroargctxt
+ \expandafter\noexpand\csname\the\macname xx\endcsname}%
+ \expandafter\xdef\csname\the\macname xx\endcsname##1{%
+ \expandafter\noexpand\csname\the\macname xxx\endcsname ##1,}%
+ \expandafter\expandafter
+ \expandafter\xdef
+ \expandafter\expandafter
+ \csname\the\macname xxx\endcsname
+ \paramlist{%
+ \egroup
+ \noexpand\norecurse{\the\macname}%
+ \noexpand\scanmacro{\temp}\egroup}%
+ \else % 10 or more:
+ \expandafter\xdef\csname\the\macname\endcsname{%
+ \noexpand\getargvals@{\the\macname}{\argl}%
+ }%
+ \global\expandafter\let\csname mac.\the\macname .body\endcsname\temp
+ \global\expandafter\let\csname mac.\the\macname .recurse\endcsname\norecurse
+ \fi
</font> \fi
\fi}
<font color='#000088'>+\catcode `\@\texiatcatcode\relax
+
</font> \def\norecurse#1{\bgroup\cslet{#1}{macsave.#1}}
% \braceorline decides whether the next nonwhitespace character is a
% {. If so it reads up to the closing }, if not, it reads the whole
% line. Whatever was read is then fed to the next control sequence
<font color='#880000'>-% as an argument (by \parsebrace or \parsearg)
</font><font color='#000088'>+% as an argument (by \parsebrace or \parsearg).
+%<span style="background-color: #FF0000"> </span>
</font> \def\braceorline#1{\let\macnamexxx=#1\futurelet\nchar\braceorlinexxx}
\def\braceorlinexxx{%
\ifx\nchar\bgroup\else
<font color='#997700'>@@ -7099,7 +7670,8 @@
</font>
% @alias.
% We need some trickery to remove the optional spaces around the equal
<font color='#880000'>-% sign. Just make them active and then expand them all to nothing.
</font><font color='#000088'>+% sign. Make them active and then expand them all to nothing.
+%
</font> \def\alias{\parseargusing\obeyspaces\aliasxxx}
\def\aliasxxx #1{\aliasyyy#1\relax}
\def\aliasyyy #1=#2\relax{%
<font color='#997700'>@@ -7120,7 +7692,8 @@
</font>
% @inforef is relatively simple.
\def\inforef #1{\inforefzzz #1,,,,**}
<font color='#880000'>-\def\inforefzzz #1,#2,#3,#4**{\putwordSee{} \putwordInfo{} \putwordfile{} \file{\ignorespaces #3{}},
</font><font color='#000088'>+\def\inforefzzz #1,#2,#3,#4**{%
+ \putwordSee{} \putwordInfo{} \putwordfile{} \file{\ignorespaces #3{}},
</font> node \samp{\ignorespaces#1{}}}
% @node's only job in TeX is to define \lastnode, which is used in
<font color='#997700'>@@ -7181,11 +7754,32 @@
</font> \toks0 = \expandafter{\lastsection}%
\immediate \writexrdef{title}{\the\toks0 }%
\immediate \writexrdef{snt}{\csname #2\endcsname}% \Ynumbered etc.
<font color='#880000'>- \safewhatsit{\writexrdef{pg}{\folio}}% will be written later, during \shipout
</font><font color='#000088'>+ \safewhatsit{\writexrdef{pg}{\folio}}% will be written later, at \shipout
</font> }%
\fi
}
<font color='#000088'>+% @xrefautosectiontitle on|off says whether @section(ing) names are used
+% automatically in xrefs, if the third arg is not explicitly specified.
+% This was provided as a "secret" @set xref-automatic-section-title
+% variable, now it's official.
+%<span style="background-color: #FF0000"> </span>
+\parseargdef\xrefautomaticsectiontitle{%
+ \def\temp{#1}%
+ \ifx\temp\onword
+ \expandafter\let\csname SETxref-automatic-section-title\endcsname
+ = \empty
+ \else\ifx\temp\offword
+ \expandafter\let\csname SETxref-automatic-section-title\endcsname
+ = \relax
+ \else
+ \errhelp = \EMsimple
+ \errmessage{Unknown @xrefautomaticsectiontitle value `\temp',
+ must be on|off}%
+ \fi\fi
+}
+
+
</font> % @xref, @pxref, and @ref generate cross-references. For \xrefX, #1 is
% the node name, #2 the name of the Info cross-reference, #3 the printed
% node name, #4 the name of the Info file, #5 the name of the printed
<font color='#997700'>@@ -7202,7 +7796,7 @@
</font> \setbox0=\hbox{\printedrefname\unskip}%
\ifdim \wd0 = 0pt
% No printed node name was explicitly given.
<font color='#880000'>- \expandafter\ifx\csname SETxref-automatic-section-title\endcsname\relax
</font><font color='#000088'>+ \expandafter\ifx\csname SETxref-automatic-section-title\endcsname \relax
</font> % Use the node name inside the square brackets.
\def\printedrefname{\ignorespaces #1}%
\else
<font color='#997700'>@@ -7357,7 +7951,8 @@
</font> \angleleft un\-de\-fined\angleright
\iflinks
\ifhavexrefs
<font color='#880000'>- \message{\linenumber Undefined cross reference `#1'.}%
</font><font color='#000088'>+ {\toks0 = {#1}% avoid expansion of possibly-complex value
+ \message{\linenumber Undefined cross reference `\the\toks0'.}}%
</font> \else
\ifwarnedxrefs\else
\global\warnedxrefstrue
<font color='#997700'>@@ -7521,7 +8116,7 @@
</font> % space to prevent strange expansion errors.)
\def\supereject{\par\penalty -20000\footnoteno =0 }
<font color='#880000'>-% @footnotestyle is meaningful for info output only.
</font><font color='#000088'>+% @footnotestyle is meaningful for Info output only.
</font> \let\footnotestyle=\comment
{\catcode `\@=11
<font color='#997700'>@@ -7584,6 +8179,8 @@
</font> % expands into a box, it must come within the paragraph, lest it
% provide a place where TeX can split the footnote.
\footstrut
<font color='#000088'>+ %
+ % Invoke rest of plain TeX footnote routine.
</font> \futurelet\next\fo@t
}
}%end \catcode `\@=11
<font color='#997700'>@@ -7671,7 +8268,7 @@
</font> it from ftp://tug.org/tex/epsf.tex.}
%
\def\image#1{%
<font color='#880000'>- \ifx\epsfbox\undefined
</font><font color='#000088'>+ \ifx\epsfbox\thisiundefined
</font> \ifwarnednoepsf \else
\errhelp = \noepsfhelp
\errmessage{epsf.tex not found, images will be ignored}%
<font color='#997700'>@@ -7687,7 +8284,7 @@
</font> % #2 is (optional) width, #3 is (optional) height.
% #4 is (ignored optional) html alt text.
% #5 is (ignored optional) extension.
<font color='#880000'>-% #6 is just the usual extra ignored arg for parsing this stuff.
</font><font color='#000088'>+% #6 is just the usual extra ignored arg for parsing stuff.
</font> \newif\ifimagevmode
\def\imagexxx#1,#2,#3,#4,#5,#6\finish{\begingroup
\catcode`\^^M = 5 % in case we're inside an example
<font color='#997700'>@@ -8136,7 +8733,7 @@
</font> %
% Latin1 (ISO-8859-1) character definitions.
\def\latonechardefs{%
<font color='#880000'>- \gdef^^a0{~}
</font><font color='#000088'>+ \gdef^^a0{\tie}
</font> \gdef^^a1{\exclamdown}
\gdef^^a2{\missingcharmsg{CENT SIGN}}
\gdef^^a3{{\pounds}}
<font color='#997700'>@@ -8166,7 +8763,7 @@
</font> \gdef^^b9{$^1$}
\gdef^^ba{\ordm}
%
<font color='#880000'>- \gdef^^bb{\guilletright}
</font><font color='#000088'>+ \gdef^^bb{\guillemetright}
</font> \gdef^^bc{$1\over4$}
\gdef^^bd{$1\over2$}
\gdef^^be{$3\over4$}
<font color='#997700'>@@ -8258,7 +8855,7 @@
</font>
% Latin2 (ISO-8859-2) character definitions.
\def\lattwochardefs{%
<font color='#880000'>- \gdef^^a0{~}
</font><font color='#000088'>+ \gdef^^a0{\tie}
</font> \gdef^^a1{\ogonek{A}}
\gdef^^a2{\u{}}
\gdef^^a3{\L}
<font color='#997700'>@@ -8339,8 +8936,8 @@
</font> \gdef^^ea{\ogonek{e}}
\gdef^^eb{\"e}
\gdef^^ec{\v e}
<font color='#880000'>- \gdef^^ed{\'\i}
- \gdef^^ee{\^\i}
</font><font color='#000088'>+ \gdef^^ed{\'{\dotless{i}}}
+ \gdef^^ee{\^{\dotless{i}}}
</font> \gdef^^ef{\v d}
%
\gdef^^f0{\dh}
<font color='#997700'>@@ -8431,7 +9028,7 @@
</font>
\gdef\DeclareUnicodeCharacter#1#2{%
\countUTFz = "#1\relax
<font color='#880000'>- \wlog{\space\space defining Unicode char U+#1 (decimal \the\countUTFz)}%
</font><font color='#000088'>+ %\wlog{\space\space defining Unicode char U+#1 (decimal \the\countUTFz)}%
</font> \begingroup
\parseXMLCharref
\def\UTFviiiTwoOctets##1##2{%
<font color='#997700'>@@ -8899,8 +9496,8 @@
</font> % Prevent underfull vbox error messages.
\vbadness = 10000
<font color='#880000'>-% Don't be so finicky about underfull hboxes, either.
-\hbadness = 2000
</font><font color='#000088'>+% Don't be very finicky about underfull hboxes, either.
+\hbadness = 6666
</font>
% Following George Bush, get rid of widows and orphans.
\widowpenalty=10000
<font color='#997700'>@@ -9107,28 +9704,21 @@
</font>
\message{and turning on texinfo input format.}
<font color='#000088'>+\def^^L{\par} % remove \outer, so ^L can appear in an @comment
+
</font> % DEL is a comment character, in case @c does not suffice.
\catcode`\^^? = 14
% Define macros to output various characters with catcode for normal text.
<font color='#880000'>-\catcode`\"=\other
-\catcode`\~=\other
-\catcode`\^=\other
-\catcode`\_=\other
-\catcode`\|=\other
-\catcode`\<=\other
-\catcode`\>=\other
-\catcode`\+=\other
-\catcode`\$=\other
-\def\normaldoublequote{"}
-\def\normaltilde{~}
-\def\normalcaret{^}
-\def\normalunderscore{_}
-\def\normalverticalbar{|}
-\def\normalless{<}
-\def\normalgreater{>}
-\def\normalplus{+}
-\def\normaldollar{$}%$ font-lock fix
</font><font color='#000088'>+\catcode`\"=\other \def\normaldoublequote{"}
+\catcode`\$=\other \def\normaldollar{$}%$ font-lock fix
+\catcode`\+=\other \def\normalplus{+}
+\catcode`\<=\other \def\normalless{<}
+\catcode`\>=\other \def\normalgreater{>}
+\catcode`\^=\other \def\normalcaret{^}
+\catcode`\_=\other \def\normalunderscore{_}
+\catcode`\|=\other \def\normalverticalbar{|}
+\catcode`\~=\other \def\normaltilde{~}
</font>
% This macro is used to make a character print one way in \tt
% (where it can probably be output as-is), and another way in other fonts,
<font color='#997700'>@@ -9221,16 +9811,16 @@
</font> % the literal character `\'.
%
@def@normalturnoffactive{%
<font color='#880000'>- @let\=@normalbackslash
</font> @let"=@normaldoublequote
<font color='#880000'>- @let~=@normaltilde
</font><font color='#000088'>+ @let$=@normaldollar %$ font-lock fix
+ @let+=@normalplus
+ @let<=@normalless
+ @let>=@normalgreater
+ @let\=@normalbackslash
</font> @let^=@normalcaret
@let_=@normalunderscore
@let|=@normalverticalbar
<font color='#880000'>- @let<=@normalless
- @let>=@normalgreater
- @let+=@normalplus
- @let$=@normaldollar %$ font-lock fix
</font><font color='#000088'>+ @let~=@normaltilde
</font> @markupsetuplqdefault
@markupsetuprqdefault
@unsepspaces
<font color='#997700'>@@ -9262,10 +9852,16 @@
</font> % Say @foo, not \foo, in error messages.
@escapechar = `@@
<font color='#000088'>+% These (along with & and #) are made active for url-breaking, so need
+% active definitions as the normal characters.
+@def@normaldot{.}
+@def@normalquest{?}
+@def@normalslash{/}
+
</font> % These look ok in all fonts, so just make them not special.
<font color='#880000'>-@catcode`@& = @other
-@catcode`@# = @other
-@catcode`@% = @other
</font><font color='#000088'>+@catcode`@& = @other @def@normalamp{&}
+@catcode`@# = @other @def@normalhash{#}
+@catcode`@% = @other @def@normalpercent{%}
</font>
@c Finally, make ` and ' active, so that txicodequoteundirected and
@c txicodequotebacktick work right in, e.g., @w{@code{`foo'}}. If we
</pre>
<p> </p>
<p>--<br />
<small>Generated by <a href="http://www.codewiz.org/projects/index.html#loginfo">Deluxe Loginfo</a> 2.122 by Bernardo Innocenti <bernie@develer.com></small></p>
</body>
</html>