\documentclass{article} \usepackage{axiom} \begin{document} \title{\$SPAD/src/search} \author{The Axiom Team} \maketitle \begin{abstract} \end{abstract} \eject \tableofcontents \eject \section{search.h} Construct a page with a menu of references to the word. The syntax of the command is: \begin{verbatim} htsearch word \end{verbatim} <>= #!/bin/sh htbindir=$AXIOM/lib htpagedir=$AXIOM/share/hypertex/pages if test -z "$1" then echo ""|$htbindir/presea case=1 - else ( cd $htpagedir; $htbindir/hthits "$1" $htpagedir/ht.db |sort -r -n +0.22 |$htbindir/presea case=0 expr="$1" -) fi @ <>= #!/bin/awk -f BEGIN {n=0;m=0 } { a[n] = $0; n=n+1; j=split($0,b,"{"); m=m+substr(b[j],1,length(b[j])-1); } END { if (case==1) printf ("\\begin{page}{staticsearchpage}{No matches found}\n") else if ( n==0 || m==0 ) printf ("\\begin{page}{staticsearchpage}{No matches found for {\\em %s}}\n",expr) else printf ("\\begin{page}{staticsearchpage}{%d matches found in %d pages for {\\em %s}}\n",m,n,expr); printf ("Matches\\tab{8}in Page\n"); printf "\\beginscroll\n"; printf "\\beginmenu\n"; for(i=0;i>= @ \eject \begin{thebibliography}{99} \bibitem{1} nothing \end{thebibliography} \end{document}