[comp.emacs] LaTeXinfo - 2 of 10

mike@ists.ists.ca (Mike Clarkson) (06/03/90)

#! /bin/sh
# This is a shell archive.  Remove anything before this line, then unpack
# it by saving it into a file and typing "sh file".  To overwrite existing
# files, type "sh file -c".  You can also feed this as standard input via
# unshar, or by typing "sh <file", e.g..  If this archive is complete, you
# will see the following message at the end:
#		"End of archive 1 (of 9)."
# Contents:  .emacs .login MANIFEST Makefile README format.sty
#   get-node.el head-fmt.el head.sty macsyma-fmt.el macsyma.sty
#   manual/Makefile manual/README manual/latexinfo.bib
#   manual/makeinfofile.el manual/sample.tex nodify-new.el nodify.el
#   praxis-fmt.el praxis.sty psfonts.sty scheme.sty smallverb.sty
# Wrapped by mike@sam on Sat Jun  2 18:18:08 1990
PATH=/bin:/usr/bin:/usr/ucb ; export PATH
if test -f '.emacs' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'.emacs'\"
else
echo shar: Extracting \"'.emacs'\" \(638 characters\)
sed "s/^X//" >'.emacs' <<'END_OF_FILE'
X;; Modify the following line to be the name of this file, and
X;; ut the in your ~/.emacs (without the semi-colons).
X;; (load-file "/usr2/ai/nesc/.emacs")
X
X;;; LaTeXinfo
X(setq latexinfo-formats-directory
X      (expand-file-name (getenv "LATEXINFO")))
X
X(setq load-path 
X      (cons
X       latexinfo-formats-directory
X       load-path))
X
X(autoload 'get-latexinfo-node "get-node.el"
X	  "Get help on a LaTeXinfo topic" t)
X
X(define-key help-map "g" 'get-latexinfo-node)
X
X(autoload 'latexinfo-format-buffer "latexinfo"
X	  "Format a buffer for LaTeXinfo" t)
X
X(autoload 'nodify-file "nodify"
X	  "Create nodes structure for a LaTeXinfo file." t)
X
X
END_OF_FILE
if test 638 -ne `wc -c <'.emacs'`; then
    echo shar: \"'.emacs'\" unpacked with wrong size!
fi
# end of '.emacs'
fi
if test -f '.login' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'.login'\"
else
echo shar: Extracting \"'.login'\" \(251 characters\)
sed "s/^X//" >'.login' <<'END_OF_FILE'
X#!/bin/csh
X
X# LaTeXinfo
Xsetenv LATEXINFO /usr2/ai/nesc/latexinfo
X
X# Add the format files to the list of directories that LaTeX searches.
Xif ( $?TEXINPUTS ) then
X	setenv TEXINPUTS "$TEXINPUTS"':'"$LATEXINFO"
X  else
X	setenv TEXINPUTS "$LATEXINFO"
Xendif
END_OF_FILE
if test 251 -ne `wc -c <'.login'`; then
    echo shar: \"'.login'\" unpacked with wrong size!
fi
# end of '.login'
fi
if test -f 'MANIFEST' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'MANIFEST'\"
else
echo shar: Extracting \"'MANIFEST'\" \(1199 characters\)
sed "s/^X//" >'MANIFEST' <<'END_OF_FILE'
X   File Name		Archive #	Description
X-----------------------------------------------------------
X .emacs                     1	
X .login                     1	
X COPYING                    2	
X MANIFEST                   1	This shipping list
X Makefile                   1	
X README                     1	
X format.sty                 1	
X get-node.el                1	
X head-fmt.el                1	
X head.sty                   1	
X latexinfo-mode.el          2	
X latexinfo.el               9	
X latexinfo.sty              2	
X macsyma-fmt.el             1	
X macsyma.sty                1	
X manual/Makefile            1	
X manual/README              1	
X manual/latexinfo.bib       1	
X manual/latexinfo.tex-aa    7	
X manual/latexinfo.tex-ab    5	
X manual/latexinfo.tex-ac    4	
X manual/latexinfo.tex-ad    6	
X manual/latexinfo.tex-ae    3	
X manual/makeinfofile.el     1	
X manual/sample.tex          1	
X manual/texindex.c          8	
X nodify-new.el              1	
X nodify.el                  1	
X praxis-fmt.el              1	
X praxis.sty                 1	
X psfonts.sty                1	
X scheme-fmt.el              2	
X scheme.sty                 1	
X smallverb.sty              1	
X tex-to-latexinfo.el        2	
END_OF_FILE
if test 1199 -ne `wc -c <'MANIFEST'`; then
    echo shar: \"'MANIFEST'\" unpacked with wrong size!
fi
# end of 'MANIFEST'
fi
if test -f 'Makefile' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'Makefile'\"
else
echo shar: Extracting \"'Makefile'\" \(959 characters\)
sed "s/^X//" >'Makefile' <<'END_OF_FILE'
XSHARDIR=/tmp/latexinfo
X
XUTILS = .login .emacs Makefile README COPYING
X
XSTYS = format.sty \
X	head.sty \
X	latexinfo.sty \
X	macsyma.sty \
X	praxis.sty \
X	psfonts.sty \
X	scheme.sty \
X	smallverb.sty
X
X
XELS = get-node.el \
X	head-fmt.el \
X	latexinfo-mode.el \
X	latexinfo.el \
X	macsyma-fmt.el \
X	nodify-new.el \
X	nodify.el \
X	praxis-fmt.el \
X	scheme-fmt.el \
X	tex-to-latexinfo.el
X
X
XMANS=	manual/Makefile \
X	manual/README \
X	manual/latexinfo.bib \
X	manual/latexinfo.tex-aa \
X	manual/latexinfo.tex-ab \
X	manual/latexinfo.tex-ac \
X	manual/latexinfo.tex-ad \
X	manual/latexinfo.tex-ae \
X	manual/makeinfofile.el \
X	manual/sample.tex \
X	manual/texindex.c
X
Xall::	manual
X
Xmanual::
X	(cd manual ; make)
X
Xshar::
X	(cd manual ; make shar)
X	makekit -o MANIFEST $(UTILS) $(SRCS) $(STYS) $(ELS) $(MANS)
X	rm -f Part00
X	cp README Part00
X	echo "#! /bin/sh" >> Part00
X	echo "mkdir manual" >> Part00
X	-mkdir $(SHARDIR)
X	mv Part?? $(SHARDIR)
X
Xclean::	
X	rm *.el~ #*
X	(cd manual ; make clean)
X
END_OF_FILE
if test 959 -ne `wc -c <'Makefile'`; then
    echo shar: \"'Makefile'\" unpacked with wrong size!
fi
# end of 'Makefile'
fi
if test -f 'README' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'README'\"
else
echo shar: Extracting \"'README'\" \(2707 characters\)
sed "s/^X//" >'README' <<'END_OF_FILE'
XThis is version 1.2 of the LaTeXinfo documentation, and is for Version 18
Xof GNU Emacs.
X
XDocumentation for GNU utilities and libraries is usually written in a
Xformat called "TeXinfo".  This document describes an enhancement
Xof this format which can be used with LaTeX instead of TeX.
X
XLaTeXinfo offers a number of advantages over TeXinfo:
X
X     
X  1. The point size or layout style of a document can be changed easily using
X     as can the `documentstyle' (article, report, book, twoside, ...).
X     
X  2. LaTeX has better error checking than TeX files, especially in
X     begin/end environments.  In addition, the LaTeX error messages are more
X     informative.  This makes it considerably easier to make extensions and
X     enhancements (read hacks).
X     
X  3. LaTeX delimits its arguments with braces, so it's easier to tell where
X     a LaTeXinfo command starts, and where it ends.
X     
X  4. Any LaTeX commands not understood by the on-line manual generator
X     (`latexinfo.el') are simply ignored.  This means that you are free to add
X     a considerable number of LaTeX commands to make you manual look pretty,
X     as long as you don't care that there will be no action taken by the 
X     Info formatting program.
X     
X  5. It is easy to add your own extensions to the on-line manual generator
X     by making GNU Emacs handlers for your LaTeX extensions.  This is
X     the Emacs counterpart to the `documentstyle' options.  LaTeXinfo looks
X     in a specified directory for GNU Elisp code that corresponds to each
X     style file.  This makes it easy to modularize you style files.
X     
X  6. LaTeX has many advantages over TeX, such as being able to
X     incorporate the BibTeX bibliography formatting program, and is much more
X     widely used than either Scribe or plain TeX.
X     
X
XTo install:
X
X1)	edit the file .login to set the LATEXINFO environment variable to 
X	point to this directory.
X2)	edit your .cshrc to include a command to source this .login file
X	each time you log in.
X3)	source this .login file now so that you can proceed.
X4)	edit the file manual/Makefile to set 
X	the name of your DVI to PS filter, and
X	the name of your GNU Emacs.
X5)	type make to make the manual and compile the .el files
X6)	move a copy of the files manual/latexinfo.info* to the info
X	directory of the GNU Emacs distribution, and edit the dir
X	file in that directory to include lines like
X
X* LaTeXinfo: (latexinfo.info).   With one source file, make either a printed 
X                        manual using LaTeX or an Info file.
X
X7)	include a copy of the .emacs file in your ~/.emacs.
X8)	print a copy of the manual/latexinfo.dvi file and enjoy.
X
X
XPlease report any errors to mike@ists.ists.ca
X
XMike Clarkson
END_OF_FILE
if test 2707 -ne `wc -c <'README'`; then
    echo shar: \"'README'\" unpacked with wrong size!
fi
# end of 'README'
fi
if test -f 'format.sty' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'format.sty'\"
else
echo shar: Extracting \"'format.sty'\" \(1593 characters\)
sed "s/^X//" >'format.sty' <<'END_OF_FILE'
X% We make @ signs act like letters, temporarily, to avoid conflict
X% between user names and internal control sequences of plain format.
X%\catcode`@=11
X
X\ifcase \@ptsize\relax 
X
X\voffset= -30pt
X\textheight 580pt 	% increase from 536pt
X\textwidth  450pt	% increase from 360pt
X\hoffset= -45pt		% compensate to keep centered
X\if@twoside 
X	\reversemarginpar	% I assume the binding side is the
X	\oddsidemargin 70pt 	% bigger margin, so reverse the
X	\evensidemargin 38pt 	% placement  of marginpars
X	\marginparwidth 40pt	% less of a margin to work with
X  \else \oddsidemargin 54pt \evensidemargin 54pt \marginparwidth 83pt 
X	\fi
X
X\or	% 11pt
X
X\voffset= -30pt
X\textheight 580pt 	% increase from 536pt
X\textwidth  450pt	% increase from 360pt
X\hoffset= -45pt		% compensate to keep centered
X\if@twoside 
X	\reversemarginpar	% I assume the binding side is the
X	\oddsidemargin 70pt 	% bigger margin, so reverse the
X	\evensidemargin 38pt 	% placement  of marginpars
X	\marginparwidth 40pt	% less of a margin to work with
X  \else \oddsidemargin 54pt \evensidemargin 54pt \marginparwidth 83pt 
X	\fi
X
X\or	% 12pt
X
X\voffset= -30pt
X\textheight 580pt 	% increase from 536pt
X\textwidth  450pt	% increase from 360pt
X\hoffset= -45pt		% compensate to keep centered
X\if@twoside 
X	\reversemarginpar	% I assume the binding side is the
X	\oddsidemargin 70pt 	% bigger margin, so reverse the
X	\evensidemargin 38pt 	% placement  of marginpars
X	\marginparwidth 40pt	% less of a margin to work with
X  \else \oddsidemargin 54pt \evensidemargin 54pt \marginparwidth 83pt 
X	\fi
X
X\fi
X
X%\catcode`@=12 % at signs are no longer letters
X
END_OF_FILE
if test 1593 -ne `wc -c <'format.sty'`; then
    echo shar: \"'format.sty'\" unpacked with wrong size!
fi
# end of 'format.sty'
fi
if test -f 'get-node.el' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'get-node.el'\"
else
echo shar: Extracting \"'get-node.el'\" \(2348 characters\)
sed "s/^X//" >'get-node.el' <<'END_OF_FILE'
X(define-key help-map "g" 'get-latexinfo-node)
X
X(defun get-latexinfo-node (string)
X  (interactive "sDescribe Latexinfo Topic: ")
X  (let* ((info-file-name
X	  (save-excursion
X	    (set-buffer "*info*")
X	    (buffer-file-name)))
X	 (index-file-name
X	  (concat
X	   (substring info-file-name 0 (- (length info-file-name) 2))
X	   "dex")))
X    (if (and (file-exists-p index-file-name)
X	     (file-exists-p info-file-name))
X	(get-node index-file-name info-file-name string)
X      (error "File(s) not found! \n  %s \n  %s"
X	     index-file-name info-file-name
X	     ))))
X
X(require 'info)
X;;(autoload 'Info-find-node "info" )
X
X(defun get-node (index-file manual-file string)
X  (interactive "fIndex File Name; \nfManual File Name; \nsTopic: ")
X    (let ((byte) (index-buffer))
X      (save-excursion
X	(find-file index-file)
X	(setq index-buffer (current-buffer))
X	(goto-char (point-min))
X	(binary-search-forward string)
X      	(setq byte (read (current-buffer))))
X      (setq manual-file
X	    (expand-file-name manual-file))
X      (find-file manual-file)
X      (save-excursion
X	(widen)
X	(goto-char byte)
X	;; Find beginning of node.
X	(search-backward "\n\^_")
X	(forward-line 2)
X	;; Get nodename spelled as it is in the node.
X	(re-search-forward "Node:[ \t]*")
X	(setq Info-current-node
X	      (buffer-substring (point)
X				(progn
X				  (skip-chars-forward "^,\t\n")
X				  (point)))))
X      (message "Node: %s File: %s"
X	    Info-current-node manual-file)
X   (Info-find-node manual-file Info-current-node)
X   (bury-buffer index-buffer)
X   (goto-char byte)))
X
X(defvar *binary-search-limit* 300
X  "The point of diminuishing returns for a binary-search.")
X
X(defun binary-search-forward (string)
X  "Search for the string STRING in the current buffer using a binary search"
X  (setq string (concat "\"" string "\""))
X  (if (< (point-max) *binary-search-limit*)
X      	(re-search-forward (concat "^" (regexp-quote string)))
X      (setq string (concat string " "))
X      (let* ((hi (point-max))
X	     (lo (point-min))
X	     (mid (/ (+ hi lo) 2))
X	     (len (length string)))
X	(while (>= (- hi lo) *binary-search-limit*)
X	  (goto-char mid)
X	  (forward-line 1)
X	  (if (string< (buffer-substring (point) (+ (point) len)) string)
X	      (setq lo mid)
X	    (setq hi mid))
X	  (setq mid (/ (+ hi lo) 2)))
X	(goto-char lo)
X	(re-search-forward (concat "^" (regexp-quote string))))))
X
END_OF_FILE
if test 2348 -ne `wc -c <'get-node.el'`; then
    echo shar: \"'get-node.el'\" unpacked with wrong size!
fi
# end of 'get-node.el'
fi
if test -f 'head-fmt.el' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'head-fmt.el'\"
else
echo shar: Extracting \"'head-fmt.el'\" \(3645 characters\)
sed "s/^X//" >'head-fmt.el' <<'END_OF_FILE'
X(require 'latexinfo)
X
X(defvar *index* nil)
X(defvar *latexinfo-index-file* nil)
X
X(defun head-fmt-hook ()
X  (save-excursion
X    (setq *index* nil)
X    (setq *latexinfo-index-file* nil)
X    (goto-char (point-min))
X    (search-forward "\\latexinfoindexname")
X    (skip-chars-forward " 	{")
X    (setq *latexinfo-index-file*
X	  (expand-file-name
X	   (buffer-substring 
X	    (point)
X	    (progn
X	      (skip-chars-forward "^ 	}\n")
X	      (point))))))
X  )
X
X(load-library "informat")
X;; We replace Info-split because we can't split and keep the index entries
X;; the same.
X(defun Info-split ()
X  (interactive)
X  (let ((lastmessage "Making tags table for Info file..."))
X    (message lastmessage)
X    (Info-tagify)
X    (message
X     (setq lastmessage "Making index for Info file..."))
X    (make-head-index)
X    (goto-char (point-min))
X    (replace-string "\b" " ")
X    (message (concat lastmessage
X		     (if (interactive-p)
X			 "done.  Now save it." "done."))))
X  )
X
X(defun make-head-index ()
X  (let ((entries  (mapcar 'find-entry *index*)))
X    (save-excursion
X      (set-buffer (head-find-buffer *latexinfo-index-file*))
X      (erase-buffer)
X      (mapcar 'add-entry  entries)
X      (insert "\n")
X      (goto-char (point-min))
X      (mapcar 'add-byte *index*)
X      (sort-lines nil (point-min) (point-max))
X      (goto-char (point-min))
X      (delete-char 1)
X      (setq buffer-file-name (expand-file-name *latexinfo-index-file*))
X      (save-buffer)
X      (bury-buffer (buffer-name))))
X  (goto-char (point-min)))
X
X(defun find-entry (byte)
X  (goto-char byte)
X  (buffer-substring byte
X		    (progn
X		      (skip-chars-forward "^\n\b(")
X		      (point))))
X
X(defun add-entry (entry)
X  (insert
X   ?\" entry ?\"
X   "\n"))
X
X(defun add-byte (byte)
X  (end-of-line)
X  (insert (concat " " byte))
X  (forward-char 1))
X
X(defun head-find-buffer (filename)
X  (let ((blist (buffer-list))
X	found)
X    (while blist
X      (save-excursion
X        (set-buffer (car blist))
X	(if (and (equal (buffer-name) (file-name-nondirectory filename))
X		 (eq major-mode 'fundamental-mode))
X	    (setq found (car blist)
X		  blist nil)
X	  (setq blist (cdr blist)))))
X    (or found
X	(create-file-buffer filename))))
X
X(put 'setindexname 'latexinfo-format 'latexinfo-discard-line-with-args)
X(defun latexinfo-format-chapter-1 (belowchar)
X  (let ((arg (latexinfo-parse-arg-discard)))
X    (setq *index* (cons (1+ latexinfo-command-start) *index*))
X    (insert ?\n arg ?\n "\\SectionPAD " belowchar?\n)
X    (forward-line -2)))
X
X(put 'head  'latexinfo-format 'latexinfo-format-head)
X(defun latexinfo-format-head ()
X  (let ((type))
X    (save-excursion
X      (forward-sexp 2)
X      (setq type (buffer-substring
X	       (1+ (point)) (1- (save-excursion (end-of-line 1) (point))))))
X      (kill-line)
X      (delete-char 1)
X    (setq *index* (cons latexinfo-command-start *index*))
X    (insert (latexinfo-parse-arg-discard))
X    ;; use back-space as a marker to show the end of the command for indexing
X    (insert "\b")
X    (insert-char ?\  (- (+ 7 fill-column) (current-column) (length type)))
X    (insert type))
X  (goto-char latexinfo-command-start))
X
X;; a dead head - an incomplete line that is neither indexed but nor LaTeX'ed
X(put 'dhead  'latexinfo-format 'latexinfo-dhead)
X(defun latexinfo-dhead ()
X  (goto-char latexinfo-command-start)
X  (delete-region (point) (progn (forward-line 2) (point))))
X
X
X(defun latexinfo-format-chapter-1 (belowchar)
X  (let ((arg (latexinfo-parse-arg-discard)))
X    (setq *index* (cons (1+ latexinfo-command-start) *index*))
X;;    (insert ?\n arg ?\b ?\n "\\SectionPAD " belowchar?\n)
X    (insert ?\n arg ?\n "\\SectionPAD " belowchar?\n)
X    (forward-line -2)))
X
X
END_OF_FILE
if test 3645 -ne `wc -c <'head-fmt.el'`; then
    echo shar: \"'head-fmt.el'\" unpacked with wrong size!
fi
# end of 'head-fmt.el'
fi
if test -f 'head.sty' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'head.sty'\"
else
echo shar: Extracting \"'head.sty'\" \(744 characters\)
sed "s/^X//" >'head.sty' <<'END_OF_FILE'
X\def\latexinfoindexname#1{}
X
X\def\newindexpg{
X  \if@filesw 
X	\newwrite\@pgindexfile
X	\immediate\openout\@pgindexfile=\jobname.pg
X	\def\head{\@bsphack\begingroup
X             \def\protect####1{\string####1\space}\@sanitize
X             \@wrfileindex\@pgindexfile}
X	\typeout{Writing index file \jobname.pg }
X	\fi}
X
X\def\@wrfileindex#1#2#3{%
X	\xdef\@gtempa{\write#1{\string \entry{#2}{#3}{#2}}}\endgroup\@gtempa
X	\typeout{#2}
X	\dosomespecials\@head
X	}
X
X% This requires \newindex{pg}
X
X\def\head{\@bsphack\begingroup \@sanitize\@index}
X\def\paragraph{\@startsection
X {paragraph}{4}{\z@}{2ex plus .5ex minus .2ex}{-1em}{\normalsize\bf}}
X\def\@head#1#2{
X	\paragraph*{#2}\hbox{}\hfil{\it#1}\linebreak[4]
X	}
X
X% An unfinished head
X\def\dhead#1#2#3#4{}
X
X
END_OF_FILE
if test 744 -ne `wc -c <'head.sty'`; then
    echo shar: \"'head.sty'\" unpacked with wrong size!
fi
# end of 'head.sty'
fi
if test -f 'macsyma-fmt.el' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'macsyma-fmt.el'\"
else
echo shar: Extracting \"'macsyma-fmt.el'\" \(1746 characters\)
sed "s/^X//" >'macsyma-fmt.el' <<'END_OF_FILE'
X(defun latexinfo-format-dots ()
X  (latexinfo-discard-command)
X  (insert "..."))
X
X(put 'Macsyma 'latexinfo-format 'latexinfo-format-Macsyma)
X(defun latexinfo-format-Macsyma ()
X  (latexinfo-parse-noarg)
X  (insert "Macsyma"))
X
X(put 'ExampleInFile 'latexinfo-format 'latexinfo-ExampleInFile)
X(defun latexinfo-ExampleInFile ()
X  (let ((arg (latexinfo-parse-arg-discard)))
X    (insert
X     "There is an example in the file: \"" arg "\".")))
X
X(put 'DemoInFile 'latexinfo-format 'latexinfo-DemoInFile)
X(defun latexinfo-DemoInFile ()
X  (let ((arg (latexinfo-parse-arg-discard)))
X      (insert
X       "There is a demo in the file: \"" arg "\".")))
X
X(put 'UsageInFile 'latexinfo-format 'latexinfo-UsageInFile)
X(defun latexinfo-UsageInFile ()
X  (let ((arg (latexinfo-parse-arg-discard)))
X    (insert
X     "There are some usage notes in the file: \"" arg "\".")))
X
X
X(put 'f 'latexinfo-format 'latexinfo-format-noop)
X(put 'fb 'latexinfo-format 'latexinfo-format-findex-plus)
X(defun latexinfo-format-findex-plus ()
X  (latexinfo-index-plus 'latexinfo-findex))
X
X(put 'v 'latexinfo-format 'latexinfo-format-noop)
X(put 'vb 'latexinfo-format 'latexinfo-format-vindex-plus)
X(defun latexinfo-format-vindex-plus ()
X  (latexinfo-index-plus 'latexinfo-vindex))
X
X(defun latexinfo-index-plus (indexvar)
X  (let ((arg (latexinfo-parse-expanded-arg)))
X    (latexinfo-discard-command)
X    (insert arg)
X    (set indexvar
X	 (cons (list arg latexinfo-last-node)
X	       (symbol-value indexvar)))))
X
X
X(put 'o 'latexinfo-format 'latexinfo-format-noop)
X(put 'concept  'latexinfo-format 'latexinfo-format-noop)
X(put 'filen 'latexinfo-format 'latexinfo-format-code)
X(put 'flushr 'latexinfo-format 'latexinfo-format-noop)
X
X(put 'pcp 'latexinfo-format 'latexinfo-discard-line-with-args)
END_OF_FILE
if test 1746 -ne `wc -c <'macsyma-fmt.el'`; then
    echo shar: \"'macsyma-fmt.el'\" unpacked with wrong size!
fi
# end of 'macsyma-fmt.el'
fi
if test -f 'macsyma.sty' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'macsyma.sty'\"
else
echo shar: Extracting \"'macsyma.sty'\" \(2669 characters\)
sed "s/^X//" >'macsyma.sty' <<'END_OF_FILE'
X% Copyright 1987 Mike Clarkson.
X% Portions of this document may be copyright
X% Massachusetts Institute of Technology
X%
X% To make a TeX copy of this manual:
X%	make sure texinfo.tex in on TeX's path
X%	tex users-doc
X%	texindex users-doc.pg
X%	texindex users-doc.vr
X%	texindex users-doc.fn
X%	texindex users-doc.cp
X%	tex users-doc
X
X% To make a GNU Emacs copy of this manual:
X%	execute the following GNU Emacs code
X%
X% (load-library "texinfmt")
X% (defun texinfo-format-dots ()
X%   (texinfo-discard-command)
X%   (insert "..."))
X% 
X% (defun make-manual ()
X%   (interactive)
X%   (put 'f 'texinfo-format 'texinfo-format-noop)
X%   (put 'v 'texinfo-format 'texinfo-format-noop)
X%   (put 'o 'texinfo-format 'texinfo-format-noop)
X%   (put 'fb 'texinfo-format 'texinfo-format-noop)
X%   (put 'vb 'texinfo-format 'texinfo-format-noop)
X%   (put 'concept  'texinfo-format 'texinfo-format-defn)
X%   (put 'filen 'texinfo-format 'texinfo-format-code)
X%   (put 'flushr 'texinfo-format 'texinfo-format-noop)
X%   (put 'head  'texinfo-format 'texinfo-format-head)
X%   (put 'DOTS 'texinfo-format 'texinfo-format-dots) ;; DUMB
X%   (let ((lastmessage "Formatting Info file..."))
X%     (message lastmessage)
X%     (texinfo-format-buffer-1)
X%     (message
X%      (setq lastmessage
X% 	   "Making tags table for Info file..."))
X%     (Info-tagify)
X%     (message (concat lastmessage
X% 		     (if (interactive-p)
X% 			 "done.  Now save it." "done."))))
X%   )
X%
X% (defun texinfo-format-head ()
X%   (kill-line)
X%   (delete-char 1)
X%   (insert (texinfo-parse-arg-discard))
X%   (goto-char texinfo-command-start))
X%
X%	Then M-x make-manual
X
X\voffset= -30pt
X\textheight 580pt 	% increase from 536pt
X\textwidth  450pt	% increase from 360pt
X\hoffset= -45pt		% compensate to keep centered
X\if@twoside 
X	\reversemarginpar	% I assume the binding side is the
X	\oddsidemargin 70pt 	% bigger margin, so reverse the
X	\evensidemargin 38pt 	% placement  of marginpars
X	\marginparwidth 40pt	% less of a margin to work with
X  \else \oddsidemargin 54pt \evensidemargin 54pt \marginparwidth 83pt 
X	\fi
X
X
X% Preliminary stuff before texinfo format is turned on
X\def\Macsyma{{\bf Macsyma}}
X
X\def\f#1{\fnindex{#1}{\sf #1}}
X\def\v#1{\vrindex{#1}{\sf #1}}
X\def\o#1{{\sf #1}}
X\def\fb#1{\fnindexbold{#1}{\large\sf #1}}
X\def\vb#1{\vrindexbold{#1}{\large\sf #1}}
X\def\concept#1{\cpindex{#1}#1}
X\def\filen#1{\tpindex{#1}{\tt #1}}
X
X\def\ExampleInFile#1{\*\noindent There is an example in the file: \filen{#1}.}
X\def\DemoInFile#1{\*\noindent There is a demo in the file: \filen{#1}.}
X\def\UsageInFile#1{\*\noindent There are some usage notes in the file: 
X\filen{#1}.}
X
X%\def\pcp#1{\marginpar{{\scriptsize #1}}\kyindex{#1}}
X\def\pcp#1{}
X
X
END_OF_FILE
if test 2669 -ne `wc -c <'macsyma.sty'`; then
    echo shar: \"'macsyma.sty'\" unpacked with wrong size!
fi
# end of 'macsyma.sty'
fi
if test -f 'manual/Makefile' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'manual/Makefile'\"
else
echo shar: Extracting \"'manual/Makefile'\" \(1336 characters\)
sed "s/^X//" >'manual/Makefile' <<'END_OF_FILE'
X# The name of the file
XMANUAL=latexinfo
X
X# The name of your DVI to PS filter
XDVIPS=dvips
X
X# The name of your GNU Emacs
XEMACS=Xemacs
X
XSPLITS = $(MANUAL).tex-aa $(MANUAL).tex-ab $(MANUAL).tex-ac \
X		$(MANUAL).tex-ad $(MANUAL).tex-ae
X
Xall:	$(MANUAL).dvi $(MANUAL).info
X
Xtexindex:	texindex.c
X	cc -O -o texindex texindex.c
X
X$(MANUAL).dvi:	texindex $(MANUAL).bbl $(MANUAL).tex
X	latex $(MANUAL)
X
X$(MANUAL).bbl:	$(MANUAL).aux $(MANUAL).bib
X	-bibtex $(MANUAL)
X
X$(MANUAL).aux:	$(MANUAL).tex
X	latex $(MANUAL)
X	if [ -s $(MANUAL).cp ] ; then \
X		texindex $(MANUAL).cp ;\
X		fi
X	if [ -s $(MANUAL).pg ] ; then \
X		texindex $(MANUAL).pg ;\
X		fi
X	if [ -s $(MANUAL).vr ] ; then \
X		texindex $(MANUAL).vr ;\
X		fi
X	if [ -s $(MANUAL).fn ] ; then \
X		texindex $(MANUAL).fn ;\
X		fi
X	if [ -s $(MANUAL).ky ] ; then \
X		texindex $(MANUAL).ky ;\
X		fi
X	if [ -s $(MANUAL).tp ] ; then \
X		texindex $(MANUAL).tp ;\
X		fi
X	latex $(MANUAL)
X
X$(MANUAL).ps:	$(MANUAL).dvi
X	$(DVIPS) $(MANUAL)
X
X$(MANUAL).info:	$(MANUAL).tex $(LATEXINFO)/latexinfo.el
X	rm -f make.el
X	sed -e "s/MANUAL/$(MANUAL)/" makeinfofile.el > make.el
X	$(EMACS) -batch -q -l make.el
X
X$(MANUAL).tex::	$(SPLITS)
X	cat $(SPLITS) >  $(MANUAL).tex
X
X
Xshar::
X	split $(MANUAL).tex $(MANUAL).tex-
X
Xclean:	
X	rm -f $(MANUAL).log $(MANUAL).blg make.el *~
X
Xveryclean:
X	rm -f $(MANUAL).ps $(MANUAL).dvi $(MANUAL).tex-??
X
END_OF_FILE
if test 1336 -ne `wc -c <'manual/Makefile'`; then
    echo shar: \"'manual/Makefile'\" unpacked with wrong size!
fi
# end of 'manual/Makefile'
fi
if test -f 'manual/README' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'manual/README'\"
else
echo shar: Extracting \"'manual/README'\" \(345 characters\)
sed "s/^X//" >'manual/README' <<'END_OF_FILE'
X\section{Added Goodies}
X
XWith the \LaTeX info distribution are some added goodies that may help
Xyou use the program.
X
X\subsection{LaTeXinfo Goodies}
X
XYou will find some added \LaTeX info styles such as \code{head}, 
X\code{macsyma}, \code{scheme}, and \code{praxis}.  These
X
X\subsection{Emacs Goodies}
X
XYou will find 
X\subsection{ Goodies}
XThere
END_OF_FILE
if test 345 -ne `wc -c <'manual/README'`; then
    echo shar: \"'manual/README'\" unpacked with wrong size!
fi
# end of 'manual/README'
fi
if test -f 'manual/latexinfo.bib' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'manual/latexinfo.bib'\"
else
echo shar: Extracting \"'manual/latexinfo.bib'\" \(1187 characters\)
sed "s/^X//" >'manual/latexinfo.bib' <<'END_OF_FILE'
X@BOOK{Lamport1986,
X	author = {Leslie Lamport},
X	year = {1986},	
X	title = {{\LaTeX} User's Guide and Reference Manual},
X	publisher = {Addison-Wesley},
X	address = {Reading, MA}
X	}
X
X@MANUAL{Stallman1986,
X	author = {R. M. Stallman},
X	year = {1986},
X	title = {The GNU Emacs Manual},
X	organization = {The Free Software Foundation},
X	address = {675 Massachusetts Ave., Cambridge MA, 02139}
X	}
X
X@MANUAL{GNUEmacsManual,
X	author = {Richard Stallman},
X	year = {1986},
X	title = {The GNU Emacs Manual},
X	organization = {The Free Software Foundation},
X	address = {675 Massachusetts Ave., Cambridge MA, 02139}
X	}
X
X@MANUAL{GDBManual,
X	author = {Richard Stallman},
X	year = {1988},
X	title = {The GDB Manual},
X	organization = {The Free Software Foundation},
X	address = {675 Massachusetts Ave., Cambridge MA, 02139}
X	}
X
X@MANUAL{BisonReferenceManual,
X	author = {Charles Donnelly and Richard Stallman},
X	year = {1988},
X	title = {The Bison Reference Manual},
X	organization = {The Free Software Foundation},
X	address = {675 Massachusetts Ave., Cambridge MA, 02139}
X	}
X
X@BOOK{Lamport,
X	author = {Leslie Lamport},
X	title = {LaTeX: A Document Preparation System},
X	publisher = {Addison-Wesley},
X	year = {1985}
X	}
X
END_OF_FILE
if test 1187 -ne `wc -c <'manual/latexinfo.bib'`; then
    echo shar: \"'manual/latexinfo.bib'\" unpacked with wrong size!
fi
# end of 'manual/latexinfo.bib'
fi
if test -f 'manual/makeinfofile.el' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'manual/makeinfofile.el'\"
else
echo shar: Extracting \"'manual/makeinfofile.el'\" \(712 characters\)
sed "s/^X//" >'manual/makeinfofile.el' <<'END_OF_FILE'
X(if (null (getenv "LATEXINFO"))
X  (error "You must define the environment variable LATEXINFO first."))
X
X(defun compile-if-necessary (file)
X  (let ((filename (expand-file-name
X		   (concat (file-name-as-directory (getenv "LATEXINFO"))
X			   file))))
X    (if (file-newer-than-file-p filename (concat filename "c"))
X	(byte-compile-file filename)
X      (message "%s is up to date." filename))
X    ))
X
X(compile-if-necessary "latexinfo.el")
X(load-file "$LATEXINFO/latexinfo.elc")
X(mapcar 'compile-if-necessary '("latexinfo-mode.el"
X				"get-node.el"
X				"macsyma-fmt.el"
X				"head-fmt.el"
X				"scheme-fmt.el"
X				"nodify.el"))
X
X(find-file "MANUAL.tex")
X(latexinfo-format-buffer t)
X(save-some-buffers t)
X(kill-emacs 0)
END_OF_FILE
if test 712 -ne `wc -c <'manual/makeinfofile.el'`; then
    echo shar: \"'manual/makeinfofile.el'\" unpacked with wrong size!
fi
# end of 'manual/makeinfofile.el'
fi
if test -f 'manual/sample.tex' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'manual/sample.tex'\"
else
echo shar: Extracting \"'manual/sample.tex'\" \(2078 characters\)
sed "s/^X//" >'manual/sample.tex' <<'END_OF_FILE'
X\documentstyle[11pt,twoside,latexinfo]{report}
X\pagestyle{empty}
X
X\begin{document}
X
X\c Declare which indices you want to make use of.
X\newindex{cp}
X
X\title{The Manual}
X
X\author{Fred Foobar,\\
X	Clarke Institute,\\
X	999 Queen Street,\\
X	Toronto, Ontario}
X
X\date{\today}
X\maketitle
X
X\c The following commands start the copyright page for the printed manual.
X\clearpage
X\vpace{0pt plus 1filll}
XCopyright \copyright\{\} year copyright-owner
X
XPermission is granted to copy and distribute modified versions of this
Xmanual under the conditions for verbatim copying, provided that the entire
Xresulting derived work is distributed under the terms of a permission
Xnotice identical to this one.
X
X\c End the Copyleft page and Turn on the headings to each page.
X\clearpage
X\pagestyle{headings}
X
X\c Use roman numerals for the page numbers and Insert the Table of Contents.
X\pagenumbering{roman}
X\tableofcontents
X
X\c End the Table of Contents and start numbering from 1 with Arabic numbers
X\clearpage
X\pagenumbering{arabic}
X
X\c Anything before the \setfilename will not appear in the Info file.
X\setfilename{themanual.info}
X
X\begin{ifinfo}
XCopyright \copyright \var{year} \var{copyright-owner}
XPut another 5 page copyleft here for the Info file.
X\end{ifinfo}
X
X\c The Top node contains the master menu for the Info file.
X\c This appears only in the Info file, not the printed manual.
X
X\node    Top,       First Chapter, (dir),    (dir)
X
X\begin{menu}
X* First Chapter::    The first chapter is the 
X                     only chapter in this sample.
X\end{menu}
X
X\node First Chapter, Concept Index, Top,Top
X\chapter{First Chapter}
X\cindex{Reference to First Chapter}
X
XThis is the contents of the first chapter. 
XHere is a numbered list.
X
X\begin{enumerate}
X\item
XThis is the first item.
X
X\item
XThis is the second item.
X\end{enumerate}
X
XThe \kbd{M-x latexinfo-format-buffer} command transforms a LaTeXinfo file
Xlike this into an Info file; and \LaTeX\ typesets it for a printed manual.
X
X\twocolumn
X\node Concept Index, Top, First Chapter, Top
X\chapter*{Concept Index}
X
X\printindex{cp}
X
X\end{document}
END_OF_FILE
if test 2078 -ne `wc -c <'manual/sample.tex'`; then
    echo shar: \"'manual/sample.tex'\" unpacked with wrong size!
fi
# end of 'manual/sample.tex'
fi
if test -f 'nodify-new.el' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'nodify-new.el'\"
else
echo shar: Extracting \"'nodify-new.el'\" \(5412 characters\)
sed "s/^X//" >'nodify-new.el' <<'END_OF_FILE'
X(setq save-all nil)
X
X(defun nodify-file () "
XInsert the \\node constructs into a texinfo buffer that contains
Xonly \\chapter, \\section ... commands."
X       (interactive)
X       (save-excursion
X	      (let (chap last-chapter
X			  last-section
X			  last-subsection
X			  last-subsubsection
X			  all up up-all)
X		     (goto-char (point-min))
X		     (delete-matching-lines "^^\\node")
X		     (goto-char (point-min))
X		     (while (re-search-forward
X				   "\\\\chapter\\|\\\\section\\|\\\\subsection\\|\\\\subsubsection"
X				   nil t)
X			    (re-search-forward "{\\([^}]*\\)}")
X			    (replace-match "{\\1}\n\\\\cindex{\\1}" t))
X		     (goto-char (point-min))
X		     (while (re-search-forward
X				   "\\\\chapter\\|\\\\section\\|\\\\subsection\\|\\\\subsubsection"
X				   nil t)
X			    (let ((match (buffer-substring
X						(match-beginning 0)
X						(match-end 0))))
X				   (cond ((equal match "\\chapter")
X						(setq last-chapter
X						       (nodify-get-name-f))
X						(setq up "Top"))
X					  ((equal match "\\section")
X						 (setq last-section
X							(nodify-get-name-f))
X						 (setq up last-chapter))
X					  ((equal match "\\subsection")
X						 (setq last-subsection
X							(nodify-get-name-f))
X						 (setq up last-section))
X					  ((equal match "\\subsubsection")
X						 (setq last-subsubsection
X							(nodify-get-name-f))
X						 (setq up last-subsection))
X					  (t (message "Help - no match  %s" match) (sit-for 10)))
X			    (setq up-all (cons up up-all))
X			    (if (bolp) (forward-char 1))
X			    (setq all (cons (count-lines 1 (point)) all)))
X			    )
X		     (setq save-all all)
X		     (message "doing the last section") (sit-for 1)
X		     (goto-line (car all))
X		     (insert "\\node{"
X			    (nodify-get-name-at-line (car all))
X			    "}")
X	(nodify-insert-to-cc) (insert "\\c This\n\t{"
X			    "Top"
X			    "}")
X	(nodify-insert-to-cc) (insert "\\c Next\n\t{"
X			    (nodify-get-name-at-line (cadr all))
X			    "}")
X	(nodify-insert-to-cc) (insert "\\c Prev\n\t{"
X			    (car up-all)
X			    "}")
X	(nodify-insert-to-cc) (insert "\\c Up\n")
X		     (message "doing the other sections") (sit-for 1)
X		     (while (> (length all) 2)
X			    (goto-line (cadr all))
X			    (let ((cur (cadr all))
X					(next (1+ (car all)))
X					(prev (caddr all))
X					(up (cadr up-all)))
X				   (insert "\\node{"
X					  (nodify-get-name-at-line cur)
X					  "}")
X	(nodify-insert-to-cc) (insert "\\c This\n\t{"
X					  (nodify-get-name-at-line next)
X					  "}")
X	(nodify-insert-to-cc) (insert "\\c Next\n\t{"
X					  (nodify-get-name-at-line prev)
X					  "}")
X	(nodify-insert-to-cc) (insert "\\c Prev\n\t{"
X					  up
X					  "}")
X	(nodify-insert-to-cc) (insert "\\c Up\n"))
X			    (setq up-all (cdr up-all))
X			    (setq all (cdr all)))
X		     (message "doing the other sections...done") (sit-for 1)
X		     (goto-line (cadr all))
X		     (insert "\\node{"
X			    (nodify-get-name-at-line (cadr all)) "}{"
X			    (nodify-get-name-at-line (1+ (car all)))
X			    "}{Top}{Top}\n")
X		     (goto-char (point-min))
X		     (if (re-search-forward "^\\\\setfilename" nil t)
X			    (progn
X				   (forward-line 1)
X				   (insert "\\node{"
X					   "Top"
X					  "}")
X	(nodify-insert-to-cc) (insert "\\c This\n\t{"
X					   (nodify-get-name-at-line
X					    (1+ (cadr all)))
X					  "}")
X	(nodify-insert-to-cc) (insert "\\c Next\n\t{"
X					   "(dir)Top"
X					  "}")
X	(nodify-insert-to-cc) (insert "\\c Prev\n\t{"
X					   "(dir)Top}"
X					  "}")
X	(nodify-insert-to-cc) (insert "\\c Up\n"))
X		       )
X		     (message "doing the chapter menus") (sit-for 1)
X		     (nodify-chapter-menus)
X		     (message "doing the chapter menus...done") (sit-for 1)
X		     )))
X
X(defun nodify-chapter-menus ()
X       (let (chap (eoc (point-max)))
X	      (goto-char (point-max))
X	      (while (re-search-backward "^.chapter" nil t)
X		     (setq chap (cons (nodify-get-name) chap))
X		     (make-section-menu "\\\\section" (point) eoc)
X		     (setq eoc (point)))
X	      (goto-char (point-min))
X	      (if (re-search-forward "\\chapter" nil t)
X		     (make-menu chap))
X	      ))
X
X(defun make-section-menu (section top bot)
X       (save-excursion
X	      (let (chap)
X		     (goto-char bot)
X		     (while (re-search-backward section top t)
X			    (setq chap (cons (nodify-get-name) chap)))
X		     (goto-char top)
X		     (if (> (length chap) 1)
X			    (progn
X				   (re-search-forward section bot t)
X				   (make-menu chap)))
X		     chap)
X	      )
X       )
X
X(defun make-menu (chap)
X       (forward-line -1)
X       (insert "\n\\begin{menu}\n")
X       (while (car chap)
X	      (insert "* " (car chap) "::\n")
X	      (setq chap (cdr chap)))
X       (insert "\\end{menu}\n\n"))
X
X(defun nodify-get-name-at-line (lineno)
X       (save-excursion
X	      (goto-line (+ 1 lineno))
X	      (nodify-get-name)))
X
X(defun nodify-get-name ()
X       (save-excursion
X	      (buffer-substring
X	      (progn (forward-word 1)
X		     (skip-chars-forward "* {")
X		     ;; (if (looking-at "[ {]") (forward-char 1))
X		     (point))
X	      (progn (end-of-line) (forward-char -1) (point)))))
X
X(defun nodify-get-name-f ()
X       (save-excursion
X	 (buffer-substring
X	  (progn 
X	    (skip-chars-forward "* {")
X	    (point))
X	  (progn (end-of-line) (forward-char -1) (point)))))
X
X(defun nodify-insert-to-cc ()
X  (let ((cc (current-column)))
X     (if (< cc comment-column)
X	 (insert (make-string (- comment-column cc) 32)))))
X
X(defun cadr (x)
X       (car (cdr x)))
X(defun caddr (x)
X       (car (cdr (cdr x))))
X
END_OF_FILE
if test 5412 -ne `wc -c <'nodify-new.el'`; then
    echo shar: \"'nodify-new.el'\" unpacked with wrong size!
fi
# end of 'nodify-new.el'
fi
if test -f 'nodify.el' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'nodify.el'\"
else
echo shar: Extracting \"'nodify.el'\" \(4577 characters\)
sed "s/^X//" >'nodify.el' <<'END_OF_FILE'
X(setq save-all nil)
X(defun nodify-file () "
XInsert the \\node constructs into a texinfo buffer that contains
Xonly \\chapter, \\section ... commands."
X       (interactive)
X       (save-excursion
X	      (let (chap last-chapter
X			  last-section
X			  last-subsection
X			  last-subsubsection
X			  all up up-all)
X		     (goto-char (point-min))
X		     (delete-matching-lines "^\\node")
X		     (goto-char (point-min))
X		     (while (re-search-forward
X				   "^\\\\chapter\\|\\\\section\\|\\\\subsection\\|\\\\subsubsection"
X				   nil t)
X			    (re-search-forward "{\\([^}]*\\)}")
X			    (replace-match "{\\1}\n\\\\cindex{\\1}" t))
X		     (goto-char (point-min))
X		     (while (re-search-forward
X				   "^\\\\chapter\\|\\\\section\\|\\\\subsection\\|\\\\subsubsection"
X				   nil t)
X			    (let ((match (buffer-substring
X						(match-beginning 0)
X						(match-end 0))))
X				   (cond ((equal match "\\chapter")
X						(setq last-chapter
X						       (nodify-get-name-f))
X						(setq up "Top"))
X					  ((equal match "\\section")
X						 (setq last-section
X							(nodify-get-name-f))
X						 (setq up last-chapter))
X					  ((equal match "\\subsection")
X						 (setq last-subsection
X							(nodify-get-name-f))
X						 (setq up last-section))
X					  ((equal match "\\subsubsection")
X						 (setq last-subsubsection
X							(nodify-get-name-f))
X						 (setq up last-subsection))
X					  (t (message "Help - no match  %s" match) (sit-for 10)))
X			    (setq up-all (cons up up-all))
X			    (if (bolp) (forward-char 1))
X			    (setq all (cons (count-lines 1 (point)) all)))
X			    )
X		     (setq save-all all)
X		     (message "doing the last section") (sit-for 1)
X		     (goto-line (car all))
X		     (insert "\\node "
X			    (nodify-get-name-at-line (car all))
X			    ", Top, "
X			    (nodify-get-name-at-line (cadr all))
X			    ", " (car up-all) "\n")
X		     (message "doing the other sections") (sit-for 1)
X		     (while (> (length all) 2)
X			    (goto-line (cadr all))
X			    (let ((cur (cadr all))
X					(next (1+ (car all)))
X					(prev (caddr all))
X					(up (cadr up-all)))
X				   (insert "\\node "
X					  (nodify-get-name-at-line cur) ", "
X					  (nodify-get-name-at-line next) ", "
X					  (nodify-get-name-at-line prev) ", "
X					  up "\n"))
X			    (setq up-all (cdr up-all))
X			    (setq all (cdr all)))
X		     (message "doing the other sections...done") (sit-for 1)
X		     (goto-line (cadr all))
X		     (insert "\\node "
X			    (nodify-get-name-at-line (cadr all)) ", "
X			    (nodify-get-name-at-line (1+ (car all)))
X			    ", Top, Top\n")
X		     (goto-char (point-min))
X		     (if (re-search-forward "^\\\\setfilename" nil t)
X			    (progn
X				   (forward-line 1)
X				   (insert "\\node Top, "
X					  (nodify-get-name-at-line
X						 (1+ (cadr all)))
X					  ", (dir)Top, (dir)Top\n")))
X		     (message "doing the chapter menus") (sit-for 1)
X		     (nodify-chapter-menus)
X		     (message "doing the chapter menus...done") (sit-for 1)
X		     )))
X
X(defun nodify-chapter-menus ()
X       (let (chap (eoc (point-max)))
X	      (goto-char (point-max))
X	      (while (re-search-backward "^.chapter" nil t)
X		     (setq chap (cons (nodify-get-name) chap))
X		     (make-section-menu "\\\\section" (point) eoc)
X		     (setq eoc (point)))
X	      (goto-char (point-min))
X	      (if (re-search-forward "\\chapter" nil t)
X		     (make-menu chap))
X	      ))
X
X(defun make-section-menu (section top bot)
X       (save-excursion
X	      (let (chap)
X		     (goto-char bot)
X		     (while (re-search-backward section top t)
X			    (setq chap (cons (nodify-get-name) chap)))
X		     (goto-char top)
X		     (if (> (length chap) 1)
X			    (progn
X				   (re-search-forward section bot t)
X				   (make-menu chap)))
X		     chap)
X	      )
X       )
X
X(defun make-menu (chap)
X       (forward-line -1)
X       (insert "\n\\begin{menu}\n")
X       (while (car chap)
X	      (insert "* " (car chap) "::\n")
X	      (setq chap (cdr chap)))
X       (insert "\\end{menu}\n\n"))
X
X(defun nodify-get-name-at-line (lineno)
X       (save-excursion
X	      (goto-line (+ 1 lineno))
X	      (nodify-get-name)))
X
X(defun nodify-get-name ()
X       (save-excursion
X	      (buffer-substring
X	      (progn (forward-word 1)
X		     (skip-chars-forward "* {")
X		     ;; (if (looking-at "[ {]") (forward-char 1))
X		     (point))
X	      (progn (end-of-line) (forward-char -1) (point)))))
X
X(defun nodify-get-name-f ()
X       (save-excursion
X	 (buffer-substring
X	  (progn 
X	    (skip-chars-forward "* {")
X	    (point))
X	  (progn (end-of-line) (forward-char -1) (point)))))
X
X(defun cadr (x)
X       (car (cdr x)))
X(defun caddr (x)
X       (car (cdr (cdr x))))
X
END_OF_FILE
if test 4577 -ne `wc -c <'nodify.el'`; then
    echo shar: \"'nodify.el'\" unpacked with wrong size!
fi
# end of 'nodify.el'
fi
if test -f 'praxis-fmt.el' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'praxis-fmt.el'\"
else
echo shar: Extracting \"'praxis-fmt.el'\" \(1850 characters\)
sed "s/^X//" >'praxis-fmt.el' <<'END_OF_FILE'
X(require 'latexinfo)
X
X;; Praxis
X;; Praxima
X;; pcp
X;; PC
X;; PCES
X
X
X(put 'ifpraxima 'latexinfo-format 'latexinfo-format-ifpraxima)
X(defun latexinfo-format-ifpraxima ()
X  (delete-region latexinfo-command-start
X		 (progn (re-search-forward "\\\\end[ {]ifpraxima[ 	}\n]")
X			(point))))
X
X(put 'endifpraxima 'latexinfo-format 'latexinfo-discard-line)
X
X(put 'praxima 'latexinfo-format 'latexinfo-format-Praxima)
X(defun latexinfo-format-Praxima ()
X  (latexinfo-parse-noarg)
X  (put 'ifpraxima 'latexinfo-format 'latexinfo-discard-line)
X  (put 'ifpraxima 'latexinfo-end 'latexinfo-discard-command)
X  )
X
X(put 'Praxis 'latexinfo-format 'latexinfo-format-Praxis)
X(defun latexinfo-format-Praxis ()
X  (latexinfo-parse-noarg)
X  (insert "Praxis"))
X
X(put 'Macsyma 'latexinfo-format 'latexinfo-format-Macsyma)
X(defun latexinfo-format-Macsyma ()
X  (latexinfo-parse-noarg)
X  (insert "Macsyma"))
X
X(put 'pcp 'latexinfo-format 'latexinfo-discard-line-with-args)
X
X(put 'PC 'latexinfo-format 'latexinfo-format-PC)
X(defun latexinfo-format-PC ()
X  (latexinfo-parse-noarg)
X  (insert "Personal Consultant"))
X
X(put 'PCES 'latexinfo-format 'latexinfo-format-PCES)
X(defun latexinfo-format-PCES ()
X  (latexinfo-parse-noarg)
X  (insert "Personal Consultant Expert System"))
X
X(put 'boxed 'latexinfo-format 'latexinfo-format-boxed)
X(put 'boxed 'latexinfo-end 'latexinfo-end-boxed)
X(defun latexinfo-format-boxed ()
X  (latexinfo-discard-line)
X  (insert "\nThe menu asks the question:\n\n")
X  (setq latexinfo-command-start (point))
X  (setq latexinfo-command-end (1+ (point)))
X  (latexinfo-push-stack 'example nil)
X  (setq fill-column (- fill-column 5))
X  )
X
X(defun latexinfo-end-boxed ()
X  (setq fill-column (+ fill-column 5))
X  (latexinfo-discard-command)
X  (let ((stacktop
X	 (latexinfo-pop-stack 'example)))
X    (latexinfo-do-itemize (nth 1 stacktop)))
X  (insert "\nThe choices are:\n"))
X
X
END_OF_FILE
if test 1850 -ne `wc -c <'praxis-fmt.el'`; then
    echo shar: \"'praxis-fmt.el'\" unpacked with wrong size!
fi
# end of 'praxis-fmt.el'
fi
if test -f 'praxis.sty' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'praxis.sty'\"
else
echo shar: Extracting \"'praxis.sty'\" \(1848 characters\)
sed "s/^X//" >'praxis.sty' <<'END_OF_FILE'
X\def\Praxis{{\bf Praxis}}
X\def\Praxima{{\bf Praxima}}
X\def\Macsyma{{\bf Macsyma}}
X
X%\def\pcp#1{\marginpar{{\scriptsize #1}}\kyindex{#1}}
X\def\pcp#1{\kyindex{#1}}
X
X\def\PC{{\bf Personal Consultant}}
X\def\PCES{{\bf Personal Consultant Expert System}}
X
X\setlength{\unitlength}{1in}
X
X\newif\if@praxima	\@praximafalse
X\def\ifpraxima{\@menu\@xifpraxima }
X\let\endifpraxima=\endgroup
X
X\begingroup \catcode `|=0 \catcode `[= 1
X\catcode`]=2 \catcode `\{=12 \catcode `\}=12
X\catcode`\\=12 
X|gdef|@xifpraxima#1\end{ifpraxima}[|end[ifpraxima]]
X|endgroup
X
X\def\praxima{\@praximatrue
X	\global\def\ifpraxima{}
X	\global\def\endifpraxima{}
X	}
X
X\def\boxed{
X\noindent\if@praxima The menu asks the question:\else
XThe question that this section addresses is:\fi\par
X\noindent\rule{\textwidth}{1mm}
X	\begin{example}}
X\def\endboxed{
X	\end{example}\noindent\rule{\textwidth}{1mm}
X	\par\noindent\if@praxima The choices are:\else
X			The possibilities are:\fi}
X
X% Make the verbatim and example environments use small tt.
X\def\@verbatim{\trivlist \item[]\if@minipage\else\vskip\parskip\fi
X\leftskip\@totalleftmargin\rightskip\z@
X\parindent\z@\parfillskip\@flushglue\parskip\z@
X\@tempswafalse \def\par{\if@tempswa\hbox{}\fi\@tempswatrue\@@par}
X\obeylines \tt\small\tt \catcode``=13 \@noligs \let\do\@makeother \dospecials}
X
X\renewenvironment{example}{\aboveenvbreak
X	\hfuzz=12truept % Don't be fussy
X	\sepspaces % Make spaces be word-separators rather than space tokens.
X	\singlespace % Single space lines
X	% The following causes blank lines not to be ignored
X	% by adding a space to the end of each line.
X	\let\par=\lisppar
X	\parskip=0pt \advance \rightskip by \lispnarrowing 
X	\advance \leftskip by \lispnarrowing
X	\parindent=0pt
X	\let\exdent=\internalexdent
X	\obeyspaces \obeylines \tt\small\tt \rawbackslash \bgroup\samepage
X		\def\next##1{}\next}{\egroup\afterenvbreak}
X
X
END_OF_FILE
if test 1848 -ne `wc -c <'praxis.sty'`; then
    echo shar: \"'praxis.sty'\" unpacked with wrong size!
fi
# end of 'praxis.sty'
fi
if test -f 'psfonts.sty' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'psfonts.sty'\"
else
echo shar: Extracting \"'psfonts.sty'\" \(946 characters\)
sed "s/^X//" >'psfonts.sty' <<'END_OF_FILE'
X% If you want to define postscript fonts instead of cm fonts.
X
X\font\fivrm  = psmtimr at 5 pt	% roman
X\font\fivbf  = psmtimb at 5 pt	% extended bold 
X\font\sixrm  = psmtimr at 6 pt	% roman
X\font\sevrm  = psmtimr at 7 pt	% roman
X\font\egtrm  = psmtimr at 8 pt	% roman
X\font\egtbf  = psmtimb at 8 pt	% extended bold 
X\font\ninrm  = psmtimr at 9 pt	% roman
X\font\ninbf  = psmtimb at 9 pt	% extended bold 
X\font\tenrm  = psmtimr at 10 pt	% roman
X\font\tenbf  = psmtimb at 10 pt	% extended bold 
X\font\elvrm  = psmtimr at 11 pt	% roman  
X\font\elvbf  = psmtimb at 11 pt	% extended bold 
X\font\twlrm  = psmtimr at 12 pt % roman  
X\font\twlbf  = psmtimb at 12 pt	% extended bold 
X\font\frtnrm  = psmtimr at 14 pt % roman  
X\font\frtnbf  = psmtimb at 14 pt % extended bold 
X\font\svtnrm  = psmtimr at 17 pt % roman  
X\font\svtnbf  = psmtimb at 17 pt % extended bold 
X\font\twtyrm  = psmtimr at 20 pt % roman  
X\font\twfvrm  = psmtimr at 25 pt % roman  
X
END_OF_FILE
if test 946 -ne `wc -c <'psfonts.sty'`; then
    echo shar: \"'psfonts.sty'\" unpacked with wrong size!
fi
# end of 'psfonts.sty'
fi
if test -f 'scheme.sty' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'scheme.sty'\"
else
echo shar: Extracting \"'scheme.sty'\" \(5030 characters\)
sed "s/^X//" >'scheme.sty' <<'END_OF_FILE'
X\newcommand{\vest}{}
X\newcommand{\dotsfoo}{$\ldots\,$}
X
X\newcommand{\sharpfoo}[1]{{\tt\##1}}
X\newcommand{\schfalse}{\sharpfoo{f}}
X\newcommand{\schtrue}{\sharpfoo{t}}
X
X\newcommand{\singlequote}{{\tt'}}  %\char19
X\newcommand{\doublequote}{{\tt"}}
X\newcommand{\backquote}{{\tt\char18}}
X\newcommand{\backwhack}{{\tt\char`\\}}
X\newcommand{\atsign}{{\tt\char`\@}}
X\newcommand{\sharpsign}{{\tt\#}}
X\newcommand{\verticalbar}{{\tt|}}
X
X\newcommand{\coerce}{\discretionary{->}{}{->}}
X
X% Knuth's \in sucks big boulders
X\def\elem{\hbox{\raise.13ex\hbox{$\scriptstyle\in$}}}
X
X\newcommand{\meta}[1]{{\rm$\langle$#1$\rangle$}}
X\let\hyper=\meta
X\newcommand{\hyperi}[1]{\hyper{#1$_1$}}
X\newcommand{\hyperii}[1]{\hyper{#1$_2$}}
X\newcommand{\hyperj}[1]{\hyper{#1$_i$}}
X\newcommand{\hypern}[1]{\hyper{#1$_n$}}
X%\newcommand{\var}[1]{\noindent\hbox{\it{}#1\/}}  % Careful, is \/ always the right thing?
X\newcommand{\vari}[1]{\var{#1$_1$}}
X\newcommand{\varii}[1]{\var{#1$_2$}}
X\newcommand{\variii}[1]{\var{#1$_3$}}
X\newcommand{\variv}[1]{\var{#1$_4$}}
X\newcommand{\varj}[1]{\var{#1$_j$}}
X\newcommand{\varn}[1]{\var{#1$_n$}}
X
X\newcommand{\vr}[1]{{\noindent\hbox{$#1$\/}}}  % Careful, is \/ always the right thing?
X\newcommand{\vri}[1]{\vr{#1_1}}
X\newcommand{\vrii}[1]{\vr{#1_2}}
X\newcommand{\vriii}[1]{\vr{#1_3}}
X\newcommand{\vriv}[1]{\vr{#1_4}}
X\newcommand{\vrj}[1]{\vr{#1_j}}
X\newcommand{\vrn}[1]{\vr{#1_n}}
X
X\newcommand{\lambdaexp}{lambda expression}
X\newcommand{\Lambdaexp}{Lambda expression}
X
X\newcommand{\domain}[1]{#1}
X\newcommand{\nodomain}[1]{}
X\newcommand{\todo}[1]{}
X
X% \frobq will make quote and backquote look nicer.
X\def\frobqcats{%\catcode`\'=13
X\catcode`\`=13{}}
X{\frobqcats
X\gdef\frobqdefs{%\def'{\singlequote}
X\def`{\backquote}}}
X\def\frobq{\frobqcats\frobqdefs}
X
X% \cf = code font
X% Unfortunately, \cf \cf won't work at all, so don't even attempt to
X% next constructions which use them...
X\newcommand{\cf}{\frenchspacing\frobq\tt}
X
X% Same as \obeycr, but doesn't do a \@gobblecr.
X{\catcode`\^^M=13
X\gdef\myobeycr{\catcode`\^^M=13 \def^^M{\\}}%
X\gdef\restorecr{\catcode`\^^M=5 }}
X
X%{\catcode`\^^I=13 \gdef\obeytabs{\catcode`\^^I=13 \def^^I{\hbox{\hskip 4em}}}}
X
X%{\obeyspaces\gdef {\hbox{\hskip0.5em}}}
X
X{\makeatletter \gdef\gobblecr{\@gobblecr}}
X
X% Scheme example environment
X% At 11 points, one column, these are about 56 characters wide.
X% That's 32 characters to the left of the => and about 20 to the right.
X
X\newenvironment{schemenoindent}{
X  % Commands for scheme examples
X  \newcommand{\ev}{\>\>\evalsto}
X  \newcommand{\lev}{\\\>\evalsto}
X  \newcommand{\unspecified}{{\em{}unspecified}}
X  \newcommand{\scherror}{{\em{}error}}
X  \small \cf \obeytabs \obeyspaces \myobeycr
X  \begin{tabbing}%
X\qquad\=\hspace*{5em}\=\hspace*{9em}\=\kill%   was 16em
X\gobblecr}{\unskip\end{tabbing}}
X
X%\newenvironment{scheme}{\begin{schemenoindent}\+\kill}{\end{schemenoindent}}
X\newenvironment{scheme}{
X  % Commands for scheme examples
X  \newcommand{\ev}{\>\>\evalsto}
X  \newcommand{\lev}{\\\>\evalsto}
X  \newcommand{\unspecified}{{\em{}unspecified}}
X  \newcommand{\scherror}{{\em{}error}}
X  \small \cf \obeyspaces \myobeycr
X  \begin{tabbing}%
X\qquad\=\hspace*{5em}\=\hspace*{9em}\=\+\kill%   was 16em
X\gobblecr}{\unskip\end{tabbing}}
X
X
X\newcommand{\evalsto}{$\Longrightarrow$}
X
X% Rationale
X
X\newenvironment{rationale}{%
X\bgroup\small\noindent{\em Rationale:}\space}{%
X\egroup}
X
X% Notes
X
X\newenvironment{note}{%
X\bgroup\small\noindent{\em Note:}\space}{%
X\egroup}
X
X% Manual entries
X
X\newenvironment{header}[1]{
X  \vspace{3.1ex plus .5ex minus .3ex}\noindent#1%
X\unpenalty\nopagebreak}{\vspace{0ex plus 1ex minus 1ex}}
X
X\newcommand{\exprtype}{syntax}
X
X% Primitive prototype
X\newcommand{\pproto}[2]{\unskip%
X\hbox{\cf\spaceskip=0.5em#1}\hfill\penalty 0%
X\hbox{ }\nobreak\hfill\hbox{\rm #2}\break}
X
X% Parenthesized prototype
X\newcommand{\proto}[3]{\pproto{(\vrindexbold{#1}\hbox{#1}{\it#2\/})}{#3}}
X
X% Variable prototype
X\newcommand{\vproto}[2]{\vrindexbold{#1}\pproto{#1}{#2}}
X
X% Random prototype
X\newcommand{\rproto}[3]{\proto{#1}{#2}{#3}}
X
X% Grammar environment
X
X\newenvironment{grammar}{
X  \def\:{\goesto{}}
X  \def\|{$\vert$}
X  \cf \myobeycr
X  \begin{tabbing}
X    %\qquad\quad \= 
X    \qquad \= $\vert$ \= \kill
X  }{\unskip\end{tabbing}}
X
X%\newcommand{\unsection}{\unskip}
X\newcommand{\unsection}{{\vskip -2ex}}
X
X% Commands for grammars
X\newcommand{\arbno}[1]{#1\hbox{\rm*}}  
X\newcommand{\atleastone}[1]{#1\hbox{$^+$}}
X
X\newcommand{\goesto}{$\longrightarrow$}
X
X\newcommand{\syntax}{{\em Syntax: }}
X\newcommand{\semantics}{{\em Semantics: }}
X
X\def\o#1{{\sf #1}}
X\def\f#1{\vrindex{#1}{\sf #1}}
X\def\v#1{\vrindex{#1}{\sf #1}}
X\def\ide#1{\vrindex{#1}{\sf #1}}
X\def\fb#1{\vrindexbold{#1}{\large\sf #1}}
X\def\vb#1{\vrindexbold{#1}{\large\sf #1}}
X\def\concept#1{\cpindex{#1}#1}
X\def\defining#1{\cpindexbold{#1}{\em #1}}
X\def\filen#1{\tpindex{#1}{\tt #1}}
X\def\fb#1{\fnindexbold{#1}{\large\sf #1}}
X\def\vb#1{\vrindexbold{#1}{\large\sf #1}}
X\def\concept#1{\cpindex{#1}#1}
X\def\filen#1{\tpindex{#1}{\tt #1}}
X
X\def\dosomespecials{\do\$\do\&\do\#\do\^\do\_}
X
END_OF_FILE
if test 5030 -ne `wc -c <'scheme.sty'`; then
    echo shar: \"'scheme.sty'\" unpacked with wrong size!
fi
# end of 'scheme.sty'
fi
if test -f 'smallverb.sty' -a "${1}" != "-c" ; then 
  echo shar: Will not clobber existing file \"'smallverb.sty'\"
else
echo shar: Extracting \"'smallverb.sty'\" \(1428 characters\)
sed "s/^X//" >'smallverb.sty' <<'END_OF_FILE'
X\message{smallverbatim,}
X\font\egttt  = cmtt8            % typewriter
X    \hyphenchar\egttt = -1      %  suppress hyphenation in \tt font
X\font\nintt  = cmtt9            % typewriter
X    \hyphenchar\nintt = -1      %  suppress hyphenation in \tt font
X \font\tentt  = cmtt10   	% typewriter
X    \hyphenchar\tentt = -1      %  suppress hyphenation in \tt font
X \font\elvtt  = cmtt10   \@halfmag % typewriter
X    \hyphenchar\elvtt = -1         %  suppress hyphenation in \tt font
X
X\renewenvironment{example}{\aboveenvbreak
X	\hfuzz=12truept % Don't be fussy
X	\sepspaces % Make spaces be word-separators rather than space tokens.
X	\singlespace % Single space lines
X	% The following causes blank lines not to be ignored
X	% by adding a space to the end of each line.
X	\let\par=\lisppar
X	\parskip=0pt \advance \rightskip by \lispnarrowing 
X	\advance \leftskip by \lispnarrowing
X	\parindent=0pt
X	\let\exdent=\internalexdent
X	\ifcase \@ptsize\relax\nintt\or\tentt\or\elvtt\fi
X	\bgroup\samepage
X\def\back{\rawbackslashxx\@gobble}
X	\obeylines\@noligs\frenchspacing\obeyspaces
X	\def\next##1{}\next}{\egroup\afterenvbreak}
X
X
X\def\@verbatim{\trivlist \item[]\if@minipage\else\vskip\parskip\fi
X\leftskip\@totalleftmargin\rightskip\z@
X\parindent\z@\parfillskip\@flushglue\parskip\z@
X\@tempswafalse 
X\def\par{\if@tempswa\hbox{}\fi\@tempswatrue\@@par}
X\obeylines \ifcase \@ptsize\relax\nintt\or\tentt\or\elvtt\fi
X\let\do\@makeother \dospecials}
X
X
END_OF_FILE
if test 1428 -ne `wc -c <'smallverb.sty'`; then
    echo shar: \"'smallverb.sty'\" unpacked with wrong size!
fi
# end of 'smallverb.sty'
fi
echo shar: End of archive 1 \(of 9\).
cp /dev/null ark1isdone
MISSING=""
for I in 1 2 3 4 5 6 7 8 9 ; do
    if test ! -f ark${I}isdone ; then
	MISSING="${MISSING} ${I}"
    fi
done
if test "${MISSING}" = "" ; then
    echo You have unpacked all 9 archives.
    rm -f ark[1-9]isdone ark[1-9][0-9]isdone
else
    echo You still need to unpack the following archives:
    echo "        " ${MISSING}
fi
##  End of shell archive.
exit 0
-- 
Mike Clarkson					mike@ists.ists.ca
Institute for Space and Terrestrial Science	uunet!attcan!ists!mike
York University, North York, Ontario,		FORTRAN - just say no. 
CANADA M3J 1P3					+1 (416) 736-5611