r478: no message
authorKevin M. Rosenberg <kevin@rosenberg.net>
Wed, 31 Jan 2001 03:39:28 +0000 (03:39 +0000)
committerKevin M. Rosenberg <kevin@rosenberg.net>
Wed, 31 Jan 2001 03:39:28 +0000 (03:39 +0000)
23 files changed:
doc/Makefile.am
doc/bullet.bmp [new file with mode: 0644]
doc/ctsim-concepts.tex [new file with mode: 0644]
doc/ctsim-gui.tex [new file with mode: 0644]
doc/ctsim-install.tex [new file with mode: 0644]
doc/ctsim-textui.tex [new file with mode: 0644]
doc/ctsim-web.tex [new file with mode: 0644]
doc/ctsim.bib [new file with mode: 0644]
doc/ctsim.hlp [new file with mode: 0644]
doc/ctsim.hpj [new file with mode: 0644]
doc/ctsim.htb [new file with mode: 0644]
doc/ctsim.tex [new file with mode: 0644]
doc/fancyhea.sty [new file with mode: 0644]
doc/logo-huge.bmp [new file with mode: 0644]
doc/logo-huge.gif [new file with mode: 0644]
doc/make-help [new file with mode: 0644]
doc/makeidx.sty [new file with mode: 0644]
doc/mysober.sty [new file with mode: 0644]
doc/mytitle.sty [new file with mode: 0644]
doc/psbox.tex [new file with mode: 0644]
doc/tex2rtf.ini [new file with mode: 0644]
doc/texhelp.sty [new file with mode: 0644]
doc/verbatim.sty [new file with mode: 0644]

index 0edfc8cad8ed6b44f38270926b0ece8403b12e78..b165afd43f76b24b76ac01a7ea93442c732c010c 100644 (file)
@@ -1,4 +1,24 @@
-docs=sgp.doc
-info_INFO=ctsim.texi
-EXTRA_DIST = ${docs} $(info_INFO) 
-SUBDIRS = tex2rtf
\ No newline at end of file
+docs=ctsim.tex ctsim.bib texhelp.sty psbox.tex logo-huge.bmp tex2rtf.ini ctsim.hpj bullet.bmp verbatim.sty mytitle.sty makeidx.sty mysober.sty fancyhea.sty ctsim.bib 
+EXTRA_DIST = ${docs} 
+
+dvi: ctsim.tex
+       bibtex ctsim
+       latex ctsim
+       makeindex ctsim
+       latex ctsim
+
+winhelp: ctsim.tex
+       rm -f ctsim.rtf ctsim.cnt
+       tex2rtf ctsim.tex ctsim.rtf -winhelp
+       hcw /c /m /e ctsim.hpj
+       mv CTSIM.HLP ctsim.hlp
+       cp ctsim.hlp ctsim.cnt ../msvc/ctsim/
+
+htmlhelp: ctsim.tex
+       rm -f ctsim*.html ctsim.hhp ctsim.hhc ctsim.hhk
+       tex2rtf ctsim.tex ctsim.html -html
+       zip ctsim.zip *.html *.gif ctsim.hhp ctsim.hhc ctsim.hhk
+       mv ctsim.zip ctsim.htb
+       cp ctsim.htb ../msvc/ctsim/.
+       cp ctsim.htb ../src/.
diff --git a/doc/bullet.bmp b/doc/bullet.bmp
new file mode 100644 (file)
index 0000000..aad8fc7
Binary files /dev/null and b/doc/bullet.bmp differ
diff --git a/doc/ctsim-concepts.tex b/doc/ctsim-concepts.tex
new file mode 100644 (file)
index 0000000..ba0c2ad
--- /dev/null
@@ -0,0 +1,22 @@
+\chapter{Concepts}\index{Concepts}%
+\setheader{{\it CHAPTER \thechapter}}{}{}{}{}{{\it CHAPTER \thechapter}}%
+\setfooter{\thepage}{}{}{}{}{\thepage}%
+
+\section{Overview}\label{conceptoverview}\index{Concepts,Overview}%
+
+\section{Phantoms}\label{conceptphantom}\index{Concepts,Phantoms}%
+\subsection{Overview}\label{phantomoverview}\index{Concepts,Phantoms,Overview}%
+\subsection{Phantom Elements}\label{phantoelements}\index{Concepts,Phantoms,Elements}
+\subsubsection{ellipse}
+\subsubsection{rectangle}
+\subsubsection{triangle}
+\subsubsection{sector}
+\subsubsection{segment}
+
+\section{Scanner}\label{conceptscanner}\index{Concepts,Scanner}%
+\subsection{Geometries}
+\subsection{Focal Length}
+\subsection{Field of View}
+
+\section{Reconstruction}\label{conceptreconstruction}\index{Concepts,Reconstruction}%
+\subsection{Filtered Backprojection}
diff --git a/doc/ctsim-gui.tex b/doc/ctsim-gui.tex
new file mode 100644 (file)
index 0000000..99bc69d
--- /dev/null
@@ -0,0 +1,14 @@
+\chapter{ctsim - the Graphical User Interface}\label{ctsim}\index{ctsim}% 
+\setheader{{\it CHAPTER \thechapter}}{}{}{}{}{{\it CHAPTER \thechapter}}%
+\setfooter{\thepage}{}{}{}{}{\thepage}%
+
+\ctsim is the graphical shell for the CTSim project. It is
+written using the wxLibrary for cross-platform compatibility with GTK,
+Motif, and Microsoft Windows. It includes all of the functionality of
+the command-line tool {\tt ctsimtext} as well as image processing and visualization features.
+
+\ctsim can open projection files, image files, phantom definition files, and plotfiles.
+
+\usage
+ctsim [OPTIONS] [files to open...]
+
diff --git a/doc/ctsim-install.tex b/doc/ctsim-install.tex
new file mode 100644 (file)
index 0000000..c5cb08d
--- /dev/null
@@ -0,0 +1,49 @@
+\chapter{Installation}\index{Installation}%
+\setheader{{\it CHAPTER \thechapter}}{}{}{}{}{{\it CHAPTER \thechapter}}%
+\setfooter{\thepage}{}{}{}{}{\thepage}%
+
+\section{Download}\label{download}\index{Installation,Download}%
+
+The latest version of CTSim, plus source code, can be accessed from:
+
+\begin{verbatim}
+http://www.ctsim.org
+ftp://ftp.ctsim.org
+\end{verbatim}
+
+It is available in Windows 95/NT/2000 and Linux GUI versions and non-GUI versions.
+
+\section{Installing Linux RPM}\index{Installation,Linux}%
+
+\section{Installing Windows Binary}\index{Installation,Windows}%
+
+\section{Build From Sources}\label{build}\index{Installation,Build}%
+
+See the INSTALL file included in the source distribution for instructions.
+
+\section{Web Requirements}\label{installreq}\index{Installation,Requirements}%
+  \begin{itemize}\itemsep=0pt
+  \item zlib Library (optional)
+        \par Used for PNG file export.
+
+  \item libpng Library (optional)
+        \par Used for PNG file export.
+       \par www.libpng.org
+
+  \item FFTW library (optional)
+       \par Used for frequency-based filtering and fourier transformations of images.
+       \par www.fftw.org
+
+  \item readline library (optional)
+       \par Used for \ctsimtext interactive shell.
+
+  \item dmalloc library (optional)
+       \par Used for debugging memory allocation
+       \par www.dmalloc.com
+
+  \item wxWindows library (optional) 
+  \par Used for platform-independent graphical interface. The graphical-shell
+  program \ctsim requires this library.  
+  \par www.wxwindows.org
+\end{itemize}
+
diff --git a/doc/ctsim-textui.tex b/doc/ctsim-textui.tex
new file mode 100644 (file)
index 0000000..3826c49
--- /dev/null
@@ -0,0 +1,210 @@
+\chapter{ctsimtext}\label{ctsimtext}\index{ctsimtext}%
+\setheader{{\it CHAPTER \thechapter}}{}{}{}{}{{\it CHAPTER \thechapter}}%
+\setfooter{\thepage}{}{}{}{}{\thepage}%
+
+\ctsimtext is a master shell for all of the command-line utilities. 
+
+\usage
+\ctsimtext can be executed without any parameters. In that case, \ctsimtext
+offers a command-line to enter the function-names and their parameters. The output of the command is displayed. Further commands may be given to \ctsimtext. The shell is exited by the {\tt quit} command.
+
+\ctsimtext can also be called to execute a single command. This is especially useful for batch files containing multiple \ctsimtext commands. This is invoked by calling \par
+{\tt ctsimtext function-name parameters...}.
+
+The available functions are:
+
+\section{if1}\label{if1}\index{ctsimtext,if1}%
+Perfoms math functions on a single image.
+
+\usage
+\begin{itemize}\itemsep=0pt
+  \item --invert
+  \item --log
+  \item --exp
+  \item --sqr
+  \item --sqrt
+\end{itemize}
+
+\section{if2}\label{if2}\index{ctsimtext,if2}%
+Perfoms math functions on a two images.
+
+\usage
+\begin{itemize}\itemsep=0pt
+  \item --add
+  \item --sub
+  \item --mul
+  \item --comp
+  \item --column-plot
+  \item --row-plot
+\end{itemize}
+
+\section{ifexport}\label{ifexport}\index{ctsimtext,ifexport}%
+Export an imagefile to a standard graphics file.
+
+\usage
+\begin{itemize}\itemsep=0pt
+  \item --format
+  \begin{itemize}\itemsep=0pt
+    \item --pgm
+    \item --pgmasc
+    \item --png
+    \item --png16
+  \end{itemize}
+  \item --center
+  \begin{itemize}\itemsep=0pt
+    \item median
+    \item mode
+    \item mean
+  \end{itemize}
+  \item --auto
+  \begin{itemize}\itemsep=0pt
+     \item --full
+     \item --std0.1
+     \item --std0.5
+     \item --std1
+     \item --std2
+     \item --std3
+  \end{itemize}
+  \item --scale
+  \item --min
+  \item --max
+\end{itemize}
+
+\section{ifinfo}\label{ifinfo}\index{ctsimtext,ifinfo}%
+
+Displays information about an imagefile.
+
+\usage
+\begin{itemize}\itemsep=0pt
+  \item --labels
+  \item --no-labels
+  \item --stats
+  \item --no-stats
+  \item --help
+\end{itemize}
+
+\section{phm2pj}\label{phm2pj}\index{ctsimtext,phm2pj}%
+Simulates collection of X-rays data (projections) around a phantom object.
+
+\usage
+phm2pj projection-file-name number-of-detectors number-of-views [options...]
+\begin{itemize}\itemsep=0pt
+  \item --phantom
+  Select a standard phantom 
+  \begin{itemize}\itemsep=0pt
+    \item herman
+    \item herman-b
+    \item shepp-logan
+    \item shepp-logan-b
+  \end{itemize}
+
+  \item --phmfile
+  Load a phantom definition definition
+
+  \item --geometry
+  \begin{itemize}\itemsep=0pt
+    \item parallel
+    \item equiangular
+    \item equilinear
+  \end{itemize}
+
+  \item --nray
+    Number of samples per each detector
+
+  \item --rotangle
+    Sets the rotation amount as a multiple of pi. For parallel geometries use
+a rotation angle of 1 and for equilinear and equiangular geometries use a rotation angle of 2.
+
+  \item --field-of-view
+    Sets the field of view as a ratio of the diameter of the phantom. For parallel geometries, using a value of 1.0 is fine. For other geometies, this should be at least 1.3 to avoid artifacts.
+
+  \item --focal-length
+    Sets the distance of the radiation source and detectors from the center of the object as a ratio of the radius of the object. For parallel geometries, a value of 1.0 is fine. For other geometries, this should be at least 2.0 to avoid artifacts.
+\end{itemize}
+
+The Herman phantom is taken with permission from Gabor Hermans 1980 book\cite{HERMAN80}. The Shepp-Logan phantom was published in 1974\cite{SHEPP74}.
+
+\section{phm2if}\label{phm2if}\index{ctsimtext,phm2if}%
+Converts a geometric phantom object into an imagefile. The size of the
+imagefile in pixels must be specified as well as the number of samples
+to average per pixel.
+
+\usage
+\begin{itemize}\itemsep=0pt
+  \item --nsamples
+\end{itemize}
+
+\section{pj2if}\label{pj2if}\index{ctsimtext,pj2if}%
+Convert a projection file into an imagefile.
+
+\usage
+\begin{itemize}\itemsep=0pt
+\item --help    Print brief online help
+\end{itemize}
+
+\section{pjinfo}\label{pjinfo}\index{ctsimtext,pjinfo}%
+Displays information about a projection file.
+
+\usage
+\begin{itemize}\itemsep=0pt
+  \item --binaryheader
+  \item --binaryview
+  \item --startview
+  \item --endview
+  \item --dump
+\end{itemize}
+
+\section{pjrec}\label{pjrec}\index{ctsimtext,pjrec}%
+Reconstructs the interior of an object from a projection file.
+
+\usage
+\begin{twocollist}
+\twocolitemruled{{\bf Parameter}}{{\bf Options}}
+\twocolitem{{\bf --filter}}
+{Selects which filter to apply to each projection. To properly reconstruct an image, this filter should be multiplied 
+by the absolute value of distance from zero frequency.
+\begin{itemize}\itemsep=0pt
+\item abs\_bandlimit
+\item abs\_cosine
+\item abs\_hamming
+\end{itemize}
+}
+\twocolitem{{\bf --filter-parameter}}{Sets the alpha level for Hamming
+  window. At setting of 0.54, this equals the Hanning window.}
+
+\twocolitem{{\bf --filter-method}}{Selects the filtering method. For large numbers of detectors, {\tt rfftw} is optimal. For smaller numbers of detectors, {\tt convolution} might be a bit faster. 
+\begin{itemize}\itemsep=0pt
+\item convolution
+\item fourier
+\item fourier\_table
+\item fftw
+\item rfftw
+\end{itemize}
+}
+
+\twocolitem{{\bf --filter-generation}}{Selects the filter generation. With convolution, {\tt direct} is the proper method to select. With any of the frequency methods, {\tt inverse-fourier} is the best method.
+\begin{itemize}\itemsep=0pt
+\item direct
+\item inverse-fourier
+\end{itemize}
+}
+\twocolitem{{\bf --interpolation}}{Interpolation technique. {\tt linear} is optimal.
+\begin{itemize}\itemsep=0pt
+\item nearest
+\item linear
+\end{itemize}
+}    
+  \twocolitem{{\bf -backprojection}}{Selects the backprojection technique. A setting of {\tt idiff3} is optimal.
+\begin{itemize}\itemsep=0pt
+\item trig
+\item table
+\item diff
+\item diff2
+\item idiff2
+\item idiff3
+\end{itemize}
+}
+\twocolitem{{\bf --zeropad}}{ Zeropad factor. A setting of {\tt 1} is optimal.}
+
+\twocolitem{{\bf --preinterpolate}}{Selects preinterpolation interpolation technique and sets the preinterpolation factor. Currently, this is experimental and does not work well.}
+\end{twocollist}
diff --git a/doc/ctsim-web.tex b/doc/ctsim-web.tex
new file mode 100644 (file)
index 0000000..b6ccb31
--- /dev/null
@@ -0,0 +1,20 @@
+\chapter{The Web Browser CGI Interface}\label{webinterface}\index{Web Interface}%
+\setheader{{\it CHAPTER \thechapter}}{}{}{}{}{{\it CHAPTER \thechapter}}%
+\setfooter{\thepage}{}{}{}{}{\thepage}%
+
+\section{Overview}\index{Web Interface,Overview}%
+The CGI program {\tt ctsim.cgi} takes projections of a standard
+phantom object, performs reconstruction, and then compares the
+rasterized phantom object with the reconstruction. The comparison is
+performed both visually by an image subtraction as well as by standard
+statistics as described by Herman\cite{HERMAN80}.
+
+\section{Requirements}\index{Web Interface,Requirements}%
+   \begin{itemize}\itemsep=0pt
+      \item Apache or other CGI compatible web server
+
+      \item Perl (version 4.0 or higher)
+
+      \item A client web browser than can display PNG files. Most
+      current web browsers support PNG.
+  \end{itemize}
diff --git a/doc/ctsim.bib b/doc/ctsim.bib
new file mode 100644 (file)
index 0000000..c29be25
--- /dev/null
@@ -0,0 +1,36 @@
+\bibliography{ctsim}
+\bibliographystyle{plain}
+
+@book{KAK87,
+  author = {A. Kak and M. Slaney},
+  title = {Principles of Computerized Tomographic Imaging},
+  publisher = {IEEE Press, New York},
+  year = {1987}
+}
+
+@book{HERMAN80,
+  author = {G.T. Herman},
+  title = {Image Reconstruction from Projections: The Fundamentals of Computerized Tomography},
+  year = {1980},
+  publisher = {Academic Press, New York, 1980}
+}
+
+@book{PRESS92,
+  author = {W.H. Press, S.A. Teukolsky, W.T. Vellerling, and B.P. Flannery},
+  title = {Numerical Recipes in C: The Art of Scientific Computing},
+  publisher = {Cambridge University Press, Cambridge},
+  edition = {Second},
+  year = {1992}
+}
+
+@article{SHEPP74,
+  author = {L. Shepp and B. Logan},
+  title = {The Fourier Reconstruction of a Head Section},
+  journal = {IEEE Transactions in Nuclear Science},
+  volume = {NS-21},
+  number = {6},
+  pages = {21-43},
+  year = {1974}
+}
+
+
diff --git a/doc/ctsim.hlp b/doc/ctsim.hlp
new file mode 100644 (file)
index 0000000..9d6c3e1
Binary files /dev/null and b/doc/ctsim.hlp differ
diff --git a/doc/ctsim.hpj b/doc/ctsim.hpj
new file mode 100644 (file)
index 0000000..1f0aa18
--- /dev/null
@@ -0,0 +1,29 @@
+; This file is maintained by HCW. Do not modify this file directly.
+
+[OPTIONS]
+COMPRESS=12 Hall Zeck
+REVISIONS=No
+LCID=0x409 0x0 0x0 ; English (United States)
+REPORT=Yes
+CONTENTS=Introduction
+TITLE=CTSim - Computed Tomography Simulator
+CNT=ctsim.cnt
+COPYRIGHT=Copyright (c) 1983-2001 Kevin Rosenberg, M.D.
+CITATION=Copyright (c) 1983-2001 Kevin Rosenberg, M.D.
+HLP=ctsim.hlp
+
+[FILES]
+ctsim.rtf
+
+[MAP]
+#include ..\..\src\ctsim-map.h
+
+[WINDOWS]
+main="",(653,102,360,600),27904,(r14876671),(r12632256),f3
+
+[CONFIG]
+CreateButton("Up", "\&Up", "JumpId(`ctsim.hlp', `Contents')")             ; Buttons
+BrowseButtons()
+
+[BAGGAGE]
+ctsim.cnt
diff --git a/doc/ctsim.htb b/doc/ctsim.htb
new file mode 100644 (file)
index 0000000..909075d
Binary files /dev/null and b/doc/ctsim.htb differ
diff --git a/doc/ctsim.tex b/doc/ctsim.tex
new file mode 100644 (file)
index 0000000..6b42f8d
--- /dev/null
@@ -0,0 +1,104 @@
+\documentclass[11pt]{report}%
+%\input{psbox.tex}
+\usepackage{texhelp}
+\usepackage{fancyheadings}
+\usepackage{mysober}
+\usepackage{mytitle}
+\usepackage{verbatim}
+\usepackage{makeidx}
+\usepackage{times}
+\usepackage{hyperref}
+
+\newcommand{\ctsim}{{\tt CTSim}}
+\newcommand{\ctsimtext}{{\tt CTSimText}}
+\newcommand{\usage}{{\bf Usage}{\par}}
+
+\newcommand{\commandref}[2]{\helpref{{\tt $\backslash$#1}}{#2}}%
+\newcommand{\commandrefn}[2]{\helprefn{{\tt $\backslash$#1}}{#2}\index{#1}}%
+\newcommand{\commandpageref}[2]{\latexignore{\helprefn{{\tt $\backslash$#1}}{#2}}\latexonly{{\tt $\backslash$#1} {\it page \pageref{#2}}}\index{#1}}%
+\newcommand{\indexit}[1]{#1\index{#1}}%
+\newcommand{\inioption}[1]{{\bf {\tt #1}}\index{#1}}%
+\parskip=10pt%
+\parindent=0pt%
+%\backgroundcolour{255;255;255}\textcolour{0;0;0}% Has an effect in HTML only
+\winhelpignore{\title{Manual for CTSim 3.0}%
+\author{Kevin Rosenberg, M.D.}%
+\date{January 2001}%
+}%
+\winhelponly{\title{Manual for CTSim 3.0}%
+\author{by Kevin Rosenberg, M.D.\\$$\image{3cm;3cm}{logo-huge.bmp}$$}%
+}%
+\makeindex%
+\begin{document}%
+\maketitle%
+\pagestyle{fancyplain}%
+\bibliographystyle{plain}%
+\pagenumbering{roman}%
+
+\setheader{{\it CONTENTS}}{}{}{}{}{{\it CONTENTS}}%
+\setfooter{\thepage}{}{}{}{}{\thepage}%
+\tableofcontents%
+
+\chapter*{Copyright notice}%
+\setheader{{\it COPYRIGHT}}{}{}{}{}{{\it COPYRIGHT}}%
+\setfooter{\thepage}{}{}{}{}{\thepage}%
+
+Copyright (c) 1983-2001 Kevin Rosenberg, M.D.
+
+Permission to use, copy, modify, and distribute this software and its
+documentation for any purpose is hereby granted without fee, provided that the
+above copyright notice, author statement and this permission notice appear in
+all copies of this software and related documentation.
+
+THE SOFTWARE IS PROVIDED ``AS-IS'' AND WITHOUT WARRANTY OF ANY KIND, EXPRESS,
+IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF
+MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
+
+IN NO EVENT SHALL KEVIN ROSENBERG BE LIABLE FOR ANY
+SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR
+ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
+WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY
+OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
+PERFORMANCE OF THIS SOFTWARE.
+
+\chapter{Introduction}\label{introduction}%
+\pagenumbering{arabic}%
+\setheader{{\it CHAPTER \thechapter}}{}{}{}{}{{\it CHAPTER \thechapter}}%
+\setfooter{\thepage}{}{}{}{}{\thepage}%
+
+\winhelponly{$$\image{3cm;3cm}{logo-huge}$$}%
+\htmlonly{$$\image{3cm;3cm}{logo-huge.gif}$$}%
+Computed Tomography is a technique for estimating the interior of an object 
+from measurement of radiation collected around the object. This radiation 
+can be either projected through or emitted from the object.
+\rtfsp\ctsim simulates the process of projecting X-rays through a phantom object.
+\rtfsp\ctsim can then reconstruct the interior of the object from the projections
+collected around the phantom object.
+
+The \ctsim package has two executable files: the graphical \helprefn{ctsim}{ctsim} and text \helprefn{ctsimtext}{ctsimtext} programs.
+
+\include{ctsim-concepts}
+
+\include{ctsim-install}
+
+\include{ctsim-gui}
+
+\include{ctsim-textui}
+
+\include{ctsim-web}
+
+\newpage
+
+\bibliographystyle{plain}
+\bibliography{ctsim}
+\addcontentsline{toc}{chapter}{Bibliography}
+\setheader{{\it REFERENCES}}{}{}{}{}{{\it REFERENCES}}%
+\setfooter{\thepage}{}{}{}{}{\thepage}%
+
+\addcontentsline{toc}{chapter}{Index}
+\setheader{{\it INDEX}}{}{}{}{}{{\it INDEX}} %
+\setfooter{\thepage}{}{}{}{}{\thepage} %
+\printindex %
+
+\end{document}%
diff --git a/doc/fancyhea.sty b/doc/fancyhea.sty
new file mode 100644 (file)
index 0000000..83914fa
--- /dev/null
@@ -0,0 +1,145 @@
+% fancyheadings.sty version 1.92
+% Fancy headers and footers.
+% Piet van Oostrum, Dept of Computer Science, University of Utrecht
+% Padualaan 14, P.O. Box 80.089, 3508 TB Utrecht, The Netherlands
+% Telephone: +31-30-531806. piet@cs.ruu.nl (mcvax!sun4nl!ruuinf!piet)
+% Sep 16, 1994
+% version 1.4: Correction for use with \reversemargin
+% Sep 29, 1994:
+% version 1.5: Added the \iftopfloat, \ifbotfloat and \iffloatpage commands
+% Oct 4, 1994:
+% version 1.6: Reset single spacing in headers/footers for use with
+% setspace.sty or doublespace.sty
+% Oct 4, 1994:
+% version 1.7: changed \let\@mkboth\markboth to
+% \def\@mkboth{\protect\markboth} to make it more robust
+% Dec 5, 1994:
+% version 1.8: corrections for amsbook/amsart: define \@chapapp and (more
+% importantly) use the \chapter/sectionmark definitions from ps@headings if
+% they exist (which should be true for all standard classes).
+% May 31, 1995:
+% version 1.9: The proposed \renewcommand{\headrulewidth}{\iffloatpage...
+% construction in the doc did not work properly with the fancyplain style. 
+% June 1, 1995:
+% version 1.91: The definition of \@mkboth wasn't restored on subsequent
+% \pagestyle{fancy}'s.
+% June 1, 1995:
+% version 1.92: The sequence \pagestyle{fancyplain} \pagestyle{plain}
+% \pagestyle{fancy} would erroneously select the plain version.
+
+\def\lhead{\@ifnextchar[{\@xlhead}{\@ylhead}}
+\def\@xlhead[#1]#2{\gdef\@elhead{#1}\gdef\@olhead{#2}}
+\def\@ylhead#1{\gdef\@elhead{#1}\gdef\@olhead{#1}}
+
+\def\chead{\@ifnextchar[{\@xchead}{\@ychead}}
+\def\@xchead[#1]#2{\gdef\@echead{#1}\gdef\@ochead{#2}}
+\def\@ychead#1{\gdef\@echead{#1}\gdef\@ochead{#1}}
+
+\def\rhead{\@ifnextchar[{\@xrhead}{\@yrhead}}
+\def\@xrhead[#1]#2{\gdef\@erhead{#1}\gdef\@orhead{#2}}
+\def\@yrhead#1{\gdef\@erhead{#1}\gdef\@orhead{#1}}
+
+\def\lfoot{\@ifnextchar[{\@xlfoot}{\@ylfoot}}
+\def\@xlfoot[#1]#2{\gdef\@elfoot{#1}\gdef\@olfoot{#2}}
+\def\@ylfoot#1{\gdef\@elfoot{#1}\gdef\@olfoot{#1}}
+
+\def\cfoot{\@ifnextchar[{\@xcfoot}{\@ycfoot}}
+\def\@xcfoot[#1]#2{\gdef\@ecfoot{#1}\gdef\@ocfoot{#2}}
+\def\@ycfoot#1{\gdef\@ecfoot{#1}\gdef\@ocfoot{#1}}
+
+\def\rfoot{\@ifnextchar[{\@xrfoot}{\@yrfoot}}
+\def\@xrfoot[#1]#2{\gdef\@erfoot{#1}\gdef\@orfoot{#2}}
+\def\@yrfoot#1{\gdef\@erfoot{#1}\gdef\@orfoot{#1}}
+
+\newdimen\headrulewidth
+\newdimen\footrulewidth
+\newdimen\plainheadrulewidth
+\newdimen\plainfootrulewidth
+\newdimen\headwidth
+\newif\if@fancyplain
+\def\fancyplain#1#2{\if@fancyplain#1\else#2\fi}
+
+% Command to reset various things in the headers:
+% a.o.  single spacing (taken from setspace.sty)
+% and the catcode of ^^M (so that epsf files in the header work if a
+% verbatim crosses a page boundary)
+\def\fancy@reset{\restorecr
+ \def\baselinestretch{1}%
+ \ifx\undefined\@newbaseline% NFSS not present; 2.09 or 2e
+  \ifx\@currsize\normalsize\@normalsize\else\@currsize\fi%
+ \else% NFSS (2.09) present
+  \@newbaseline%
+ \fi}
+
+% Initialization of the head and foot text.
+
+\headrulewidth 0.4pt
+\footrulewidth\z@
+\plainheadrulewidth\z@
+\plainfootrulewidth\z@
+
+\lhead[\fancyplain{}{\sl\rightmark}]{\fancyplain{}{\sl\leftmark}}
+%  i.e. empty on ``plain'' pages, \rightmark on even, \leftmark on odd pages
+\chead{}
+\rhead[\fancyplain{}{\sl\leftmark}]{\fancyplain{}{\sl\rightmark}}
+%  i.e. empty on ``plain'' pages, \leftmark on even, \rightmark on odd pages
+\lfoot{}
+\cfoot{\rm\thepage} % page number
+\rfoot{}
+
+% Put together a header or footer given the left, center and
+% right text, fillers at left and right and a rule.
+% The \lap commands put the text into an hbox of zero size,
+% so overlapping text does not generate an errormessage.
+
+\def\@fancyhead#1#2#3#4#5{#1\hbox to\headwidth{\fancy@reset\vbox{\hbox
+{\rlap{\parbox[b]{\headwidth}{\raggedright#2\strut}}\hfill
+\parbox[b]{\headwidth}{\centering#3\strut}\hfill
+\llap{\parbox[b]{\headwidth}{\raggedleft#4\strut}}}\headrule}}#5}
+
+
+\def\@fancyfoot#1#2#3#4#5{#1\hbox to\headwidth{\fancy@reset\vbox{\footrule
+\hbox{\rlap{\parbox[t]{\headwidth}{\raggedright#2\strut}}\hfill
+\parbox[t]{\headwidth}{\centering#3\strut}\hfill
+\llap{\parbox[t]{\headwidth}{\raggedleft#4\strut}}}}}#5}
+
+\def\headrule{{\if@fancyplain\let\headrulewidth\plainheadrulewidth\fi
+\hrule\@height\headrulewidth\@width\headwidth \vskip-\headrulewidth}}
+
+\def\footrule{{\if@fancyplain\let\footrulewidth\plainfootrulewidth\fi
+\vskip-0.3\normalbaselineskip\vskip-\footrulewidth
+\hrule\@width\headwidth\@height\footrulewidth\vskip0.3\normalbaselineskip}}
+
+\def\ps@fancy{%
+\@ifundefined{@chapapp}{\let\@chapapp\chaptername}{}%for amsbook
+\@ifundefined{chapter}{\def\sectionmark##1{\markboth
+{\uppercase{\ifnum \c@secnumdepth>\z@
+ \thesection\hskip 1em\relax \fi ##1}}{}}%
+\def\subsectionmark##1{\markright {\ifnum \c@secnumdepth >\@ne
+ \thesubsection\hskip 1em\relax \fi ##1}}}%
+{\def\chaptermark##1{\markboth {\uppercase{\ifnum \c@secnumdepth>\m@ne
+ \@chapapp\ \thechapter. \ \fi ##1}}{}}
+\def\sectionmark##1{\markright{\uppercase{\ifnum \c@secnumdepth >\z@
+ \thesection. \ \fi ##1}}}}%
+\csname ps@headings\endcsname % use \ps@headings defaults if they exist
+\ps@@fancy
+\gdef\ps@fancy{\@fancyplainfalse\ps@@fancy}%
+\headwidth\textwidth}
+\def\ps@fancyplain{\ps@fancy \let\ps@plain\ps@plain@fancy}
+\def\ps@plain@fancy{\@fancyplaintrue\ps@@fancy}
+\def\ps@@fancy{%
+\def\@mkboth{\protect\markboth}%
+\def\@oddhead{\@fancyhead\@lodd\@olhead\@ochead\@orhead\@rodd}%
+\def\@oddfoot{\@fancyfoot\@lodd\@olfoot\@ocfoot\@orfoot\@rodd}%
+\def\@evenhead{\@fancyhead\@rodd\@elhead\@echead\@erhead\@lodd}%
+\def\@evenfoot{\@fancyfoot\@rodd\@elfoot\@ecfoot\@erfoot\@lodd}%
+}
+\def\@lodd{\if@reversemargin\hss\else\relax\fi}
+\def\@rodd{\if@reversemargin\relax\else\hss\fi}
+
+\let\latex@makecol\@makecol
+\def\@makecol{\let\topfloat\@toplist\let\botfloat\@botlist\latex@makecol}
+\def\iftopfloat#1#2{\ifx\topfloat\empty #2\else #1\fi}
+\def\ifbotfloat#1#2{\ifx\botfloat\empty #2\else #1\fi}
+\def\iffloatpage#1#2{\if@fcolmade #1\else #2\fi}
+
diff --git a/doc/logo-huge.bmp b/doc/logo-huge.bmp
new file mode 100644 (file)
index 0000000..a51df36
Binary files /dev/null and b/doc/logo-huge.bmp differ
diff --git a/doc/logo-huge.gif b/doc/logo-huge.gif
new file mode 100644 (file)
index 0000000..aee56d2
Binary files /dev/null and b/doc/logo-huge.gif differ
diff --git a/doc/make-help b/doc/make-help
new file mode 100644 (file)
index 0000000..1ad3b6b
--- /dev/null
@@ -0,0 +1,12 @@
+rm -f ctsim.rtf ctsim.cnt
+tex2rtf ctsim.tex ctsim.rtf -winhelp
+hcw /c /m /e ctsim.hpj
+mv CTSIM.HLP ctsim.hlp
+cp ctsim.hlp ctsim.cnt ../../msvc/ctsim/
+rm -f ctsim*.html ctsim.hhp ctsim.hhc ctsim.hhk
+tex2rtf ctsim.tex ctsim.html -html
+zip ctsim.zip *.html *.gif ctsim.hhp ctsim.hhc ctsim.hhk
+mv ctsim.zip ctsim.htb
+cp ctsim.htb ../../msvc/ctsim
+
diff --git a/doc/makeidx.sty b/doc/makeidx.sty
new file mode 100644 (file)
index 0000000..4fbb9ae
--- /dev/null
@@ -0,0 +1,11 @@
+% makeidx.sty 20-Jan-87   modified for international usage
+%
+% Modified by J.Schrod (TeXsys).
+% according to the suggestion of H.Partl (TU Wien) in german.sty
+% to make caption names adaptable to other languages.
+\@ifundefined{seeterm}{\def\seeterm{see}}{} % <-----------
+\def\see#1#2{{\em \seeterm\/} #1}
+\def\printindex{\@input{\jobname.ind}}
diff --git a/doc/mysober.sty b/doc/mysober.sty
new file mode 100644 (file)
index 0000000..a6f73a6
--- /dev/null
@@ -0,0 +1,154 @@
+% SOBER.STY van Nico Poppelier
+% Adapted by Julian Smart for his own
+% nefarious purposes
+% --------------------------------------
+% Koppen van secties, subsecties, ...
+% --------------------------------------
+%
+% --------------------------------------
+% fontgrootte en regelafstand
+% (met de notatie X/Y wordt bedoeld
+%  'letter X op regelafstand Y')
+% --------------------------------------
+%
+%                10pt     11pt     12pt
+% \scriptsize    7/ 8     8/ 9.5   8/ 9.5
+% \tiny          5/ 6     6/ 7     6/ 7
+% \small         9/11    10/12    11/13.6
+% \footnotesize  8/ 9.5   9/11    10/12
+% \@normalsize  10/12    11/13.6  12/15
+% \large        12/14    12/14    14/18
+% \Large        14/18    14/18    17/22
+% \LARGE        17/22    17/22    20/25
+% \huge         20/25    20/25    25/30
+% \Huge         25/30    25/30    25/30
+%
+% de syntax van \@startsection is:
+%   \@startsection
+%     {Name}{Level}{Indent}{Before_skip}{After_Skip}{Type_face}
+%     Indent     : inspring van kop vanaf linkermarge
+%     Before_skip: wit boven kopje
+%                  (< 0 geeft aan dat eerste alinea niet inspringt)
+%     After_skip : wit onder kopje indien >= 0
+%                  horizontaal wit na kopje,
+%                  met kopje op de regel indien < 0
+%
+% notatie voor <glue>: <dimen>(<stretch>)(<shrink>)
+%
+% in LaTeX's standaard-stijlen (onafhankelijk van \@ptsize):
+%
+%               Indent     Before_skip           After_skip     Type_face
+% section       0          -3.5ex (-1ex)(-0.2ex)  2.3ex(0.2ex) \Large\bf
+% subsection    0          -3.25ex(-1ex)(-0.2ex)  1.5ex(0.2ex) \large\bf
+% subsubsection 0          -3.25ex(-1ex)(-0.2ex)  1.5ex(0.2ex) \normalsize\bf
+% paragraph     0           3.25ex( 1ex)( 0.2ex) -1em()()      \normalsize\bf
+% subparagraph  \parindent  3.25ex( 1ex)( 0.2ex) -1em()()      \normalsize\bf
+%
+%
+% in een soberder uitvoering (onafhankelijk van \@ptsize):
+%
+\def\section{\@startsection{section}{1}
+%{\z@}{-2.5ex plus -0.5ex minus -0.1ex}{0.5ex plus 0.1ex}{\large\bf}}
+{\z@}{-2.5ex plus -0.5ex minus -0.1ex}{0.5ex plus 0.1ex}{\large\bf}}
+\def\subsection{\@startsection{subsection}{2}
+{\z@}{-2.25ex plus -0.3ex minus -0.2ex}{0.05ex plus 0.05ex}{\normalsize\bf}}
+\def\subsubsection{\@startsection{subsubsection}{3}
+{\z@}{-2.25ex plus -0.3ex minus -0.2ex}{0.05ex plus 0.05ex}{\normalsize\sc}}
+\def\paragraph{\@startsection{paragraph}{4}
+{\z@}{2ex plus 0.5ex minus 0.1ex}{-0.7em}{\normalsize\it}}
+\def\subparagraph{\@startsection{subparagraph}{4}
+{\parindent}{2ex plus 0.5ex minus 0.1ex}{-0.7em}{\normalsize\it}}
+%
+% --------------------------------------
+% Hoofdstuk-koppen
+% --------------------------------------
+%
+% LaTeX's book style (standaard documentstijl) definieert
+% de hoofdstuk-koppen onafhankelijk van \@ptsize
+%
+
+\def\@makechapterhead#1{\vspace*{20pt}%
+% Next line repaired by Piet van Oostrum - June 14, 1991.
+%{\parindent 0pt\Large\bf \ifnum\c@secnumdepth>\m@ne\thechapter \fi
+{\parindent 0pt\LARGE\bf \ifnum\c@secnumdepth>\m@ne\thechapter. \hskip 1em \fi%
+{\raggedright\LARGE\bf #1}\\\rule[10pt]{\textwidth}{0.3mm}\par\nobreak \vskip25pt} }
+
+\def\@makeschapterhead#1{
+ \vspace*{20pt} { \parindent 0pt \raggedright
+ \LARGE\bf#1\par\nobreak\vskip25pt } }
+%
+% --------------------------------------
+% List-omgevingen (itemize en enumerate)
+% --------------------------------------
+%
+% De volgende parameters zijn relevant in een list-omgeving:
+%
+%   \labelsep     : afstand tussen label en item
+%   \labelwidth   : breedte van label
+%   \leftmargin   : afstand tussen linkermarge en item
+%   \rightmargin  : afstand tussen item en rechtermarge
+%   \listparindent: indentatie voor vervolg-alinea's in item
+%   \parsep       : verticaal wit tussen vervolg-alinea's in item
+%   \itemsep      : verticaal wit tussen opeenvolgende item's
+%   \topsep,
+%   \partopsep    : wit boven item 1 = \topsep + \parskip
+%                    (geen alinea-overgang boven lijst)
+%                   wit boven item 1 = \topsep + \parskip + \partopsep
+%                    (alinea-overgang boven lijst)
+%
+% zie verder LaTeX-boek 5.7.1 en C.5.3
+% --------------------------------------
+%
+% De parameters voor niveau 1 worden gedefinieerd op top-niveau en
+% \@listi definieert uitsluitend \leftmargin
+%
+% size = small (9pt, 10pt, 11pt)
+\def\@listi{\topsep 0.4ex \parsep 0pt \itemsep \parsep}
+% \topsep 4pt(2pt)(2pt)  6pt(2pt)(2pt)  9pt(3pt)(5pt)
+% \parsep 2pt(1pt)(1pt)  3pt(2pt)(1pt) 4.5pt(2pt)(1pt)
+%
+% size = footnotesize (8pt, 9pt, 10pt)
+\def\@listi{\topsep 0.4ex \parsep 0pt \itemsep \parsep}
+% \topsep 3pt(1pt)(1pt) 4pt(2pt)(2pt) 6pt(2pt)(2pt)
+% \parsep 2pt(1pt)(1pt) 2pt(1pt)(1pt) 3pt(2pt)(1pt)
+%
+% size = normalsize (and bigger)
+% \parskip    0pt(1pt) 0pt(1pt) 0pt(1pt)
+% \parindent  15pt 17pt 1.5em
+% \topsep      8pt(2pt)(4pt) 9pt(3pt)(5pt) 10pt(4pt)(6pt)
+% \partopsep   2pt(1pt)(1pt) 3pt(1pt)(2pt) 3pt(2pt)(2pt)
+% \itemsep     4pt(2pt)(1pt) 4.5pt(2pt)(1pt)  5pt(2.5pt)(1pt
+% \parsep  4pt(2pt)(1pt) 4.5pt(2pt)(1pt) 5pt(2.5pt)(1pt)
+\topsep 0.4ex \partopsep 0pt \itemsep 0pt \parsep 0pt
+%
+% \leftmargini  2.5em \leftmarginii 2.2em \leftmarginiii 1.87em
+% \leftmarginiv 1.7em \leftmarginv  1.0em \leftmarginvi  1.0em
+%
+% \leftmargin\leftmargini
+% \labelwidth\leftmargini\advance\labelwidth-\labelsep
+% \labelsep 0.5em
+%
+% \def\@listi{\leftmargin\leftmargini}
+%
+\def\@listii{\leftmargin\leftmarginii
+ \labelwidth\leftmarginii\advance\labelwidth-\labelsep
+% \topsep 4pt(2pt)(1pt) 4.5pt(2pt)(1pt) 5pt(2.5pt)(1pt)
+% \parsep 2pt(1pt)(1pt) 2pt(1pt)(1pt)   2.5pt(1pt)(1pt)
+ \topsep 0pt \parsep 0pt \itemsep \parsep}
+%
+\def\@listiii{\leftmargin\leftmarginiii
+ \labelwidth\leftmarginiii\advance\labelwidth-\labelsep
+% \topsep    2pt(1pt)(1pt) 2pt(1pt)(1pt) 2.5pt(1pt)(1pt)
+% \partopsep 1pt(0pt)(1pt) 1pt(0pt)(1pt) 1pt(0pt)(1pt)
+ \parsep \z@ \topsep 0pt \partopsep 0pt \itemsep \topsep}
+%
+% \def\@listiv{\leftmargin\leftmarginiv
+%  \labelwidth\leftmarginiv\advance\labelwidth-\labelsep}
+%
+% \def\@listv{ \leftmargin\leftmarginv
+%  \labelwidth\leftmarginv\advance\labelwidth-\labelsep}
+%
+% \def\@listvi{\leftmargin\leftmarginvi
+%  \labelwidth\leftmarginvi\advance\labelwidth-\labelsep}
+
diff --git a/doc/mytitle.sty b/doc/mytitle.sty
new file mode 100644 (file)
index 0000000..4d5652c
--- /dev/null
@@ -0,0 +1,30 @@
+% mytitle.sty
+
+\def\maketitle{\begin{titlepage}
+\let\footnotesize\small \let\footnoterule\relax \setcounter{page}{0}
+%\null
+%\vfil
+\vspace*{2cm}\begin{flushleft}
+{\huge \sf\@title\\\rule{\textwidth}{0.5mm}} \vskip 3em {\large \lineskip .75em
+{\sf\@author}
+\par}
+\vskip 1.5em {\large\sf \@date \par} \end{flushleft} \par
+\@thanks
+\vfill
+{\sf\small\begin{flushright}%
+Heart Hospital of New Mexico\\
+Albuquerque, New Mexico\\
+Tel. 1-505-724-2378
+\end{flushright}}
+\null
+\end{titlepage}
+\setcounter{footnote}{0} \let\thanks\relax
+\gdef\@thanks{}\gdef\@author{}\gdef\@title{}\let\maketitle\relax}
+\def\abstractname{Abstract} % <----------
+\def\abstract{\titlepage
+\null\vfil
+\begin{center}
+{\bf \abstractname} % <----------
+% {\bf Abstract}
+\end{center}}
+\def\endabstract{\par\vfil\null\endtitlepage}
diff --git a/doc/psbox.tex b/doc/psbox.tex
new file mode 100644 (file)
index 0000000..b7438f4
--- /dev/null
@@ -0,0 +1,520 @@
+%
+%              %%%%%%%    %%%%%        %%%%%%    %%%%%   %     %
+%              %      %  %             %     %  %     %   %   %
+%              %      %  %             %     %  %     %    % %
+%              %%%%%%%    %%%%%        %%%%%%   %     %     %
+%              %               %       %     %  %     %    % %
+%              %               %       %     %  %     %   %   %
+%              %         %%%%%%        %%%%%%    %%%%%   %     %
+%
+%              By Jean Orloff
+%              Comments & suggestions by e-mail: ORLOFF@surya11.cern.ch
+%              No modification of this file allowed if not e-sent to me.
+%
+% A simple way to measure the size of encapsulated postscript figures
+%   from inside TeX, and to use it for automatically formatting texts
+%   with inserted figures. Works both under Plain TeX-based macros
+%   (Phyzzx, Harvmac, Psizzl, ...) and LaTeX environment.
+% Provides exactly the same result on any PostScript printer provided
+%   the single instruction \psfor... is changed to fit the needs of the
+%   particular dvi->ps translator used.
+% History:
+%   1.31: adds \psforDVIALW(?)
+%   1.30: adds \splitfile & \joinfiles for multi-file management
+%   1.24: fix error handling & add \psonlyboxes
+%   1.23: adds \putsp@ce for OzTeX fix
+%   1.22: makes \drawingBox \global for use in Phyzzx
+%   1.21: accepts %%BoundingBox: (atend)
+%   1.20: tries to add \psfordvitps for the TeXPS package.
+%   1.10: adds \psforoztex, error handling...
+%2345678 1 2345678 2 2345678 3 2345678 4 2345678 5 2345678 6 2345678 7 23456789
+%
+\def\temp{1.31}
+\let\tempp=\relax
+\expandafter\ifx\csname psboxversion\endcsname\relax
+  \message{version: \temp}
+\else
+    \ifdim\temp cm>\psboxversion cm
+      \message{version: \temp}
+    \else
+      \message{psbox(\psboxversion) is already loaded: I won't load
+        psbox(\temp)!}
+      \let\temp=\psboxversion
+      \let\tempp=\endinput
+    \fi
+\fi
+\tempp
+\let\psboxversion=\temp
+\catcode`\@=11
+% Every macro likes a little privacy...
+%
+% Some common defs
+%
+\def\execute#1{#1}% NOT stupid: cs in #1 are then identified BEFORE execution
+\def\psm@keother#1{\catcode`#112\relax}% borrowed from latex
+\def\executeinspecs#1{%
+\execute{\begingroup\let\do\psm@keother\dospecials\catcode`\^^M=9#1\endgroup}}
+%
+%Trying to tame the variety of \special commands for Postscript: the
+%  universal internal command \PSspeci@l##1##2 takes ##1 to be the
+%  filename and ##2 to be the integer scale factor*1000 (as for usual
+%   TeX \scale commands)
+%
+\def\psfortextures{%     For TeXtures on the Macintosh
+%-----------------
+\def\PSspeci@l##1##2{%
+\special{illustration ##1\space scaled ##2}%
+}}
+%
+\def\psfordvitops{%      For the DVItoPS converter on IBM mainframes
+%----------------
+\def\PSspeci@l##1##2{%
+\special{dvitops: import ##1\space \the\drawingwd \the\drawinght}%
+}}
+%
+\def\psfordvips{%      For DVIPS converter on VAX, UNIX and PC's
+%--------------
+\def\PSspeci@l##1##2{%
+%    \special{/@scaleunit 1000 def}% never read dox without trying!
+\d@my=0.1bp \d@mx=\drawingwd \divide\d@mx by\d@my%
+\special{PSfile=##1\space llx=\psllx\space lly=\pslly\space%
+urx=\psurx\space ury=\psury\space rwi=\number\d@mx}%
+}}
+%
+\def\psforoztex{%        For the OzTeX shareware on the Macintosh
+%--------------
+\def\PSspeci@l##1##2{%
+\special{##1 \space
+      ##2 1000 div dup scale
+      \putsp@ce{\number-\psllx} \putsp@ce{\number-\pslly} translate
+}%
+}}
+\def\putsp@ce#1{#1 }
+%
+\def\psfordvitps{%       From the UNIX TeXPS package, vers.>3.12
+%---------------
+% Convert a dimension into the number \psn@sp (in scaled points)
+\def\psdimt@n@sp##1{\d@mx=##1\relax\edef\psn@sp{\number\d@mx}}
+\def\PSspeci@l##1##2{%
+% psfig.psr contains the def of "startTexFig": if you can locate it
+% and include the correct pathname, it should work
+\special{dvitps: Include0 "psfig.psr"}% contains def of "startTexFig"
+\psdimt@n@sp{\drawingwd}
+\special{dvitps: Literal "\psn@sp\space"}
+\psdimt@n@sp{\drawinght}
+\special{dvitps: Literal "\psn@sp\space"}
+\psdimt@n@sp{\psllx bp}
+\special{dvitps: Literal "\psn@sp\space"}
+\psdimt@n@sp{\pslly bp}
+\special{dvitps: Literal "\psn@sp\space"}
+\psdimt@n@sp{\psurx bp}
+\special{dvitps: Literal "\psn@sp\space"}
+\psdimt@n@sp{\psury bp}
+\special{dvitps: Literal "\psn@sp\space startTexFig\space"}
+\special{dvitps: Include1 "##1"}
+\special{dvitps: Literal "endTexFig\space"}
+}}
+\def\psforDVIALW{%   Try for dvialw, a UNIX public domain
+%---------------
+\def\PSspeci@l##1##2{
+\special{language "PS"
+literal "##2 1000 div dup scale"
+include "##1"}}}
+\def\psonlyboxes{%     Draft-like behaviour if none of the others works
+%---------------
+\def\PSspeci@l##1##2{%
+\at(0cm;0cm){\boxit{\vbox to\drawinght
+  {\vss
+  \hbox to\drawingwd{\at(0cm;0cm){\hbox{(##1)}}\hss}
+  }}}
+}%
+}
+%
+\def\psloc@lerr#1{%
+\let\savedPSspeci@l=\PSspeci@l%
+\def\PSspeci@l##1##2{%
+\at(0cm;0cm){\boxit{\vbox to\drawinght
+  {\vss
+  \hbox to\drawingwd{\at(0cm;0cm){\hbox{(##1) #1}}\hss}
+  }}}
+\let\PSspeci@l=\savedPSspeci@l% restore normal output for other figs!
+}%
+}
+%
+%\def\psfor...  add your own!
+%
+%  \ReadPSize{PSfilename} reads the dimensions of a PostScript drawing
+%      and stores it in \drawinght(wd)
+\newread\pst@mpin
+\newdimen\drawinght\newdimen\drawingwd
+\newdimen\psxoffset\newdimen\psyoffset
+\newbox\drawingBox
+\newif\ifNotB@undingBox
+\newhelp\PShelp{Proceed: you'll have a 5cm square blank box instead of
+your graphics (Jean Orloff).}
+\def\@mpty{}
+\def\s@tsize#1 #2 #3 #4\@ndsize{
+  \def\psllx{#1}\def\pslly{#2}%
+  \def\psurx{#3}\def\psury{#4}%  needed by a crazyness of dvips!
+  \ifx\psurx\@mpty\NotB@undingBoxtrue% this is not a valid one!
+  \else
+    \drawinght=#4bp\advance\drawinght by-#2bp
+    \drawingwd=#3bp\advance\drawingwd by-#1bp
+%  !Units related by crazy factors as bp/pt=72.27/72 should be BANNED!
+  \fi
+  }
+\def\sc@nline#1:#2\@ndline{\edef\p@rameter{#1}\edef\v@lue{#2}}
+\def\g@bblefirstblank#1#2:{\ifx#1 \else#1\fi#2}
+\def\psm@keother#1{\catcode`#112\relax}% borrowed from latex
+\def\execute#1{#1}% Seems stupid, but cs are identified BEFORE execution
+{\catcode`\%=12
+\xdef\B@undingBox{%%BoundingBox}
+}   %% is not a true comment in PostScript, even if % is!
+\def\ReadPSize#1{
+ \edef\PSfilename{#1}
+ \openin\pst@mpin=#1\relax
+ \ifeof\pst@mpin \errhelp=\PShelp
+   \errmessage{I haven't found your postscript file (\PSfilename)}
+   \psloc@lerr{was not found}
+   \s@tsize 0 0 142 142\@ndsize
+   \closein\pst@mpin
+ \else
+   \immediate\write\psbj@inaux{#1,}
+   \loop
+     \executeinspecs{\catcode`\ =10\global\read\pst@mpin to\n@xtline}
+     \ifeof\pst@mpin
+       \errhelp=\PShelp
+       \errmessage{(\PSfilename) is not an Encapsulated PostScript File:
+           I could not find any \B@undingBox: line.}
+       \edef\v@lue{0 0 142 142:}
+       \psloc@lerr{is not an EPSFile}
+       \NotB@undingBoxfalse
+     \else
+       \expandafter\sc@nline\n@xtline:\@ndline
+       \ifx\p@rameter\B@undingBox\NotB@undingBoxfalse
+         \edef\t@mp{%
+           \expandafter\g@bblefirstblank\v@lue\space\space\space}
+         \expandafter\s@tsize\t@mp\@ndsize
+       \else\NotB@undingBoxtrue
+       \fi
+     \fi
+   \ifNotB@undingBox\repeat
+   \closein\pst@mpin
+ \fi
+\message{#1}
+}
+%
+% \psboxto(xdim;ydim){psfilename}: you specify the dimensions and
+%    TeX uniformly scales to fit the largest one. If xdim=0pt, the
+%    scale is fully determined by ydim and vice versa.
+%    Notice: psboxes are a real vboxes; couldn't take hbox otherwise all
+%    indentation and all cr's would be interpreted as spaces (hugh!).
+%
+\newcount\xscale \newcount\yscale \newdimen\pscm\pscm=1cm
+\newdimen\d@mx \newdimen\d@my
+\let\ps@nnotation=\relax
+\def\psboxto(#1;#2)#3{\vbox{
+   \ReadPSize{#3}
+   \divide\drawingwd by 1000
+   \divide\drawinght by 1000
+   \d@mx=#1
+   \ifdim\d@mx=0pt\xscale=1000
+         \else \xscale=\d@mx \divide \xscale by \drawingwd\fi
+   \d@my=#2
+   \ifdim\d@my=0pt\yscale=1000
+         \else \yscale=\d@my \divide \yscale by \drawinght\fi
+   \ifnum\yscale=1000
+         \else\ifnum\xscale=1000\xscale=\yscale
+                    \else\ifnum\yscale<\xscale\xscale=\yscale\fi
+              \fi
+   \fi
+   \divide \psxoffset by 1000\multiply\psxoffset by \xscale
+   \divide \psyoffset by 1000\multiply\psyoffset by \xscale
+   \global\divide\pscm by 1000
+   \global\multiply\pscm by\xscale
+   \multiply\drawingwd by\xscale \multiply\drawinght by\xscale
+   \ifdim\d@mx=0pt\d@mx=\drawingwd\fi
+   \ifdim\d@my=0pt\d@my=\drawinght\fi
+   \message{scaled \the\xscale}
+ \hbox to\d@mx{\hss\vbox to\d@my{\vss
+   \global\setbox\drawingBox=\hbox to 0pt{\kern\psxoffset\vbox to 0pt{
+      \kern-\psyoffset
+      \PSspeci@l{\PSfilename}{\the\xscale}
+      \vss}\hss\ps@nnotation}
+   \global\ht\drawingBox=\the\drawinght
+   \global\wd\drawingBox=\the\drawingwd
+   \baselineskip=0pt
+   \copy\drawingBox
+ \vss}\hss}
+  \global\psxoffset=0pt
+  \global\psyoffset=0pt% These are local to one figure
+  \global\pscm=1cm
+  \global\drawingwd=\drawingwd
+  \global\drawinght=\drawinght
+}}
+%
+% \psboxscaled{scalefactor*1000}{PSfilename} allows to bypass the
+%   rounding errors of TeX integer divisions for situations where the
+%   TeX box should fit the original BoundingBox with a precision better
+%   than 1/1000.
+%
+\def\psboxscaled#1#2{\vbox{
+  \ReadPSize{#2}
+  \xscale=#1
+  \message{scaled \the\xscale}
+  \divide\drawingwd by 1000\multiply\drawingwd by\xscale
+  \divide\drawinght by 1000\multiply\drawinght by\xscale
+  \divide \psxoffset by 1000\multiply\psxoffset by \xscale
+  \divide \psyoffset by 1000\multiply\psyoffset by \xscale
+  \global\divide\pscm by 1000
+  \global\multiply\pscm by\xscale
+  \global\setbox\drawingBox=\hbox to 0pt{\kern\psxoffset\vbox to 0pt{
+     \kern-\psyoffset
+     \PSspeci@l{\PSfilename}{\the\xscale}
+     \vss}\hss\ps@nnotation}
+  \global\ht\drawingBox=\the\drawinght
+  \global\wd\drawingBox=\the\drawingwd
+  \baselineskip=0pt
+  \copy\drawingBox
+  \global\psxoffset=0pt
+  \global\psyoffset=0pt% These are local to one figure
+  \global\pscm=1cm
+  \global\drawingwd=\drawingwd
+  \global\drawinght=\drawinght
+}}
+%
+%  \psbox{PSfilename} makes a TeX box having the minimal size to
+%      enclose the picture
+\def\psbox#1{\psboxscaled{1000}{#1}}
+%
+%
+%  \joinfiles file1, file2, ...n \into joinedfilename .
+%     makes one file out of many
+%  \splitfile joinedfilename
+%     the opposite
+%
+%\def\execute#1{#1}% NOT stupid: cs in #1 are then identified BEFORE execution
+%\def\psm@keother#1{\catcode`#112\relax}% borrowed from latex
+%\def\executeinspecs#1{%
+%\execute{\begingroup\let\do\psm@keother\dospecials\catcode`\^^M=9#1\endgroup}}
+%\newread\pst@mpin
+\newif\ifn@teof\n@teoftrue
+\newif\ifc@ntrolline
+\newif\ifmatch
+\newread\j@insplitin
+\newwrite\j@insplitout
+\newwrite\psbj@inaux
+\immediate\openout\psbj@inaux=psbjoin.aux
+\immediate\write\psbj@inaux{\string\joinfiles}
+\immediate\write\psbj@inaux{\jobname,}
+%
+% We redefine input to keep track of the various files inputted
+%
+\immediate\let\oldinput=\input
+\def\input#1 {
+ \immediate\write\psbj@inaux{#1,}
+ \oldinput #1 }
+\def\empty{}
+\def\setmatchif#1\contains#2{
+  \def\match##1#2##2\endmatch{
+    \def\tmp{##2}
+    \ifx\empty\tmp
+      \matchfalse
+    \else
+      \matchtrue
+    \fi}
+  \match#1#2\endmatch}
+\def\warnopenout#1#2{
+ \setmatchif{TrashMe,psbjoin.aux,psbjoin.all}\contains{#2}
+ \ifmatch
+ \else
+   \immediate\openin\pst@mpin=#2
+   \ifeof\pst@mpin
+     \else
+     \errhelp{If the content of this file is so precious to you, abort (ie
+press x or e) and rename it before retrying.}
+     \errmessage{I'm just about to replace your file named #2}
+   \fi
+   \immediate\closein\pst@mpin
+ \fi
+ \message{#2}
+ \immediate\openout#1=#2}
+%  No comments allowed below: % will have an unusual catcode
+{
+\catcode`\%=12
+\gdef\splitfile#1 {
+ \immediate\openin\j@insplitin=#1
+ \message{Splitting file #1 into:}
+ \warnopenout\j@insplitout{TrashMe}
+ \loop
+   \ifeof
+     \j@insplitin\immediate\closein\j@insplitin\n@teoffalse
+   \else
+     \n@teoftrue
+     \executeinspecs{\global\read\j@insplitin to\spl@tinline\expandafter
+       \ch@ckbeginnewfile\spl@tinline%Beginning-Of-File-Named:%\endcheck}
+     \ifc@ntrolline
+     \else
+       \toks0=\expandafter{\spl@tinline}
+       \immediate\write\j@insplitout{\the\toks0}
+     \fi
+   \fi
+ \ifn@teof\repeat
+ \immediate\closeout\j@insplitout}
+\gdef\ch@ckbeginnewfile#1%Beginning-Of-File-Named:#2%#3\endcheck{
+ \def\t@mp{#1}
+ \ifx\empty\t@mp
+   \def\t@mp{#3}
+   \ifx\empty\t@mp
+     \global\c@ntrollinefalse
+   \else
+     \immediate\closeout\j@insplitout
+     \warnopenout\j@insplitout{#2}
+     \global\c@ntrollinetrue
+   \fi
+ \else
+   \global\c@ntrollinefalse
+ \fi}
+\gdef\joinfiles#1\into#2 {
+ \message{Joining following files into}
+ \warnopenout\j@insplitout{#2}
+ \message{:}
+ {
+ \edef\w@##1{\immediate\write\j@insplitout{##1}}
+ \w@{% This text was produced with psbox's \string\joinfiles.}
+ \w@{% To decompose and tex it:}
+ \w@{%-save this with a filename CONTAINING ONLY LETTERS, and no extensions}
+ \w@{% (say, JOINTFIL), in some uncrowded directory;}
+ \w@{%-make sure you can \string\input\space psbox.tex (version>=1.3);}
+ \w@{%-tex JOINTFIL using Plain, or LaTeX, or whatever is needed by}
+ \w@{% the first part in the joining (after splitting JOINTFIL into}
+ \w@{% it's constituents, TeX will try to process it as it stands).}
+ \w@{\string\input\space psbox.tex}
+ \w@{\string\splitfile{\string\jobname}}
+ }
+ \tre@tfilelist#1, \endtre@t
+ \immediate\closeout\j@insplitout}
+\gdef\tre@tfilelist#1, #2\endtre@t{
+ \def\t@mp{#1}
+ \ifx\empty\t@mp
+   \else
+   \llj@in{#1}
+   \tre@tfilelist#2, \endtre@t
+ \fi}
+\gdef\llj@in#1{
+ \immediate\openin\j@insplitin=#1
+ \ifeof\j@insplitin
+   \errmessage{I couldn't find file #1.}
+   \else
+   \message{#1}
+   \toks0={%Beginning-Of-File-Named:#1}
+   \immediate\write\j@insplitout{\the\toks0}
+   \executeinspecs{\global\read\j@insplitin to\oldj@ininline}
+   \loop
+     \ifeof\j@insplitin\immediate\closein\j@insplitin\n@teoffalse
+       \else\n@teoftrue
+       \executeinspecs{\global\read\j@insplitin to\j@ininline}
+       \toks0=\expandafter{\oldj@ininline}
+       \let\oldj@ininline=\j@ininline
+       \immediate\write\j@insplitout{\the\toks0}
+     \fi
+   \ifn@teof
+   \repeat
+   \immediate\closein\j@insplitin
+ \fi}
+}
+% To be put at the end of a file, for making an tar-like file containing
+%   everything it used.
+\def\autojoin{
+ \immediate\write\psbj@inaux{\string\into\space psbjoin.all}
+ \immediate\closeout\psbj@inaux
+ \input psbjoin.aux
+}
+%
+%  Annotations & Captions etc...
+%
+%
+% \centinsert{anybox} is just a centered \midinsert, but is included as
+%    people barely use the original inserts from TeX.
+%
+\def\centinsert#1{\midinsert\line{\hss#1\hss}\endinsert}
+\def\psannotate#1#2{\def\ps@nnotation{#2\global\let\ps@nnotation=\relax}#1}
+\def\pscaption#1#2{\vbox{
+   \setbox\drawingBox=#1
+   \copy\drawingBox
+   \vskip\baselineskip
+   \vbox{\hsize=\wd\drawingBox\setbox0=\hbox{#2}
+     \ifdim\wd0>\hsize
+       \noindent\unhbox0\tolerance=5000
+    \else\centerline{\box0}
+    \fi
+}}}
+% for compatibility with older versions
+\def\psfig#1#2#3{\pscaption{\psannotate{#1}{#2}}{#3}}
+\def\psfigurebox#1#2#3{\pscaption{\psannotate{\psbox{#1}}{#2}}{#3}}
+%
+% \at(#1;#2)#3 puts #3 at #1-higher and #2-right of the current
+%    position without moving it (to be used in annotations).
+\def\at(#1;#2)#3{\setbox0=\hbox{#3}\ht0=0pt\dp0=0pt
+  \rlap{\kern#1\vbox to0pt{\kern-#2\box0\vss}}}
+%
+% \gridfill(ht;wd) makes a 1cm*1cm grid of ht by wd whose lower-left
+%   corner is the current point
+\newdimen\gridht \newdimen\gridwd
+\def\gridfill(#1;#2){
+  \setbox0=\hbox to 1\pscm
+  {\vrule height1\pscm width.4pt\leaders\hrule\hfill}
+  \gridht=#1
+  \divide\gridht by \ht0
+  \multiply\gridht by \ht0
+  \gridwd=#2
+  \divide\gridwd by \wd0
+  \multiply\gridwd by \wd0
+  \advance \gridwd by \wd0
+  \vbox to \gridht{\leaders\hbox to\gridwd{\leaders\box0\hfill}\vfill}}
+%
+% Useful to measure where to put annotations
+\def\fillinggrid{\at(0cm;0cm){\vbox{
+  \gridfill(\drawinght;\drawingwd)}}}
+%
+% \textleftof\anybox: Sample text\endtext
+%   inserts "Sample text" on the left of \anybox ie \vbox, \psbox.
+%   \textrightof is the symmetric (not documented, too uggly)
+% Welcome any suggestion about clean wraparound macros from
+%   TeXhackers reading this
+%
+\def\textleftof#1:{
+  \setbox1=#1
+  \setbox0=\vbox\bgroup
+    \advance\hsize by -\wd1 \advance\hsize by -2em}
+\def\textrightof#1:{
+  \setbox0=#1
+  \setbox1=\vbox\bgroup
+    \advance\hsize by -\wd0 \advance\hsize by -2em}
+\def\endtext{
+  \egroup
+  \hbox to \hsize{\valign{\vfil##\vfil\cr%
+\box0\cr%
+\noalign{\hss}\box1\cr}}}
+%
+% \frameit{\thick}{\skip}{\anybox}
+%    draws with thickness \thick a box around \anybox, leaving \skip of
+%    blank around it. eg \frameit{0.5pt}{1pt}{\hbox{hello}}
+% \boxit{\anybox} is a shortcut.
+\def\frameit#1#2#3{\hbox{\vrule width#1\vbox{
+  \hrule height#1\vskip#2\hbox{\hskip#2\vbox{#3}\hskip#2}%
+        \vskip#2\hrule height#1}\vrule width#1}}
+\def\boxit#1{\frameit{0.4pt}{0pt}{#1}}
+%
+%
+\catcode`\@=12 % cs containing @ are unreachable
+%
+% CUSTOMIZE YOUR DEFAULT DRIVER:
+%    Uncomment the line corresponding to your TeX system:
+%\psfortextures%     For TeXtures on the Macintosh
+%\psforoztex   %     For OzTeX shareware on the Macintosh
+%\psfordvitops %     For the DVItoPS converter for TeX on IBM mainframes
+ \psfordvips   %     For DVIPS converter on VAX and UNIX
+%\psfordvitps  %     For dvitps from TeXPS package under UNIX
+%\psforDVIALW  %     For DVIALW, UNIX public domain
+%\psonlyboxes  %     Blank Boxes (when all else fails).
diff --git a/doc/tex2rtf.ini b/doc/tex2rtf.ini
new file mode 100644 (file)
index 0000000..15548a6
--- /dev/null
@@ -0,0 +1,10 @@
+winHelpVersion = 4
+winHelpContents = yes
+#generateHPJ = yes
+htmlWorkshopFiles = true
+combineSubSections = true
+runTwice = yes
+useUpButton = yes
+winHelpTitle = "CTSim Manual"
+
+
diff --git a/doc/texhelp.sty b/doc/texhelp.sty
new file mode 100644 (file)
index 0000000..af91bd5
--- /dev/null
@@ -0,0 +1,298 @@
+% LaTeX style file
+% Name:   texhelp.sty
+% Author: Julian Smart
+%
+% Purpose
+% -------
+% Style file to enable the simultaneous preparation of printed LaTeX and on-line
+% hypertext manuals.
+% Use in conjunction with Tex2RTF (see Tex2RTF documentation).
+%
+% Note that if a non-ASCII character starts a newline and there should be a space
+% between the last word on the previous line and the first word on this line,
+% you need to use \rtfsp to generate a space in Windows Help. \rtfsp is ignored
+% in all other formats.
+%
+% Julian Smart
+% Artificial Intelligence Applications Institute
+%
+%
+% ============== C++/CLIPS Documentation Facilities ==============
+%
+% Each class definition should be typeset with e.g.
+%
+% \section{\class{Name}: Parent}
+%
+% followed by a description of the class.
+% Each member should follow:
+%
+% \membersection{wxName::Member}
+%
+% with a description of what this member does.
+% Then, one (or more if overloaded) member (function) in detail:
+%
+% \func{return type}{name}{args}
+% or
+% \member{type}{name}
+%
+% where args is a list of \param{type}{name}, ...
+
+% Function, e.g.
+% e.g. to typeset
+%
+% void DoIt(char *string);
+%
+% write:
+%
+% \func{void}{DoIt}{\param{char *}{string}}
+%
+
+\newcommand{\func}[3]{\hangafter=1\noindent\hangindent=10mm
+{{\it #1} {\bf #2}\index{#2}}(#3)}
+
+% For function/type definition where the name is a pointer,
+% e.g. to typeset
+%
+% typedef void (*wxFunction)(wxObject&)
+%
+% write:
+%
+% \pfunc{typedef void}{wxFunction}{param{wxObject&}}
+
+\newcommand{\pfunc}[3]{\hangafter=1\noindent\hangindent=10mm
+{{\it #1} ({\bf *#2})\index{#2}}(#3)}
+
+% Use an ordinary \section command for class name definitions.
+
+% This is used for a member, such as wxBitmap: GetDepth
+\newcommand{\membersection}[1]{\subsection*{#1}\index{#1}}
+
+% CLIPS function
+\newcommand{\clipsfunc}[3]{\hangafter=1\noindent\hangindent=10mm
+{{\bf #1} ({\bf #2}\index{#2}}#3)}
+
+\newcommand{\clipssection}[1]{\chapter{#1}}
+
+% This is used for a CLIPS function name
+\newcommand{\functionsection}[1]{\subsection*{#1}}
+
+% Member: a type and a name
+\newcommand{\member}[2]{{\bf #1 \it #2}}
+
+% C++ Parameter: a type and a name (no intervening space)
+\newcommand{\param}[2]{{\it #1}{\bf #2}}
+
+% CLIPS Parameter: a type and a name (one intervening space)
+\newcommand{\cparam}[2]{{\bf #1} {\it #2}}
+
+% Class: puts in index
+\newcommand{\class}[1]{#1\index{#1}}
+
+%\newcommand{\docparam}[2]{\parskip=0pt {\it #1}\par\parskip=10pt\begin{indented}{1cm}{#2}\end{indented}}
+
+% Void type
+\newcommand{\void}{{\it void}}
+
+% Typeset destructor
+\newcommand{\destruct}[1]{{$\sim$}#1}
+
+% Typeset insert/extract operators
+\newcommand{\cinsert}{$<<$}
+\newcommand{\cextract}{$>>$}
+
+
+% =================== Hypertext facilities ===================
+%
+% To insert hyperlinks (or references, in Latex), \label the sections
+% or membersections \label{ref-label} immediately after the section, on the same line,
+% and use \helpref{text-to-show}{ref-label} to make a reference.
+%
+
+% Type text with section reference
+\newcommand{\helpref}[2]{{\it #1} (p.\ \pageref{#2}) }
+
+% Type text with URL in verbatim mode
+\newcommand{\urlref}[2]{#1 (\verb$#2$)}
+
+% Don't typeset section number in LaTeX
+\newcommand{\helprefn}[2]{{\it #1}}
+
+% Like helpref, but popup text in WinHelp instead of hyperlinked
+\newcommand{\popref}[2]{{\it #1}}
+
+% Like footnote, but popup text.
+\newcommand{\footnotepopup}[2]{{\it #1}\footnote{#2}}
+
+% =================== On-line help specific macros ===================
+%
+
+% Global document font size/family, help only.
+\newcommand{\helpfontsize}[1]{}
+\newcommand{\helpfontfamily}[1]{}
+
+% Ignore in all on-line help
+\newcommand{\helpignore}[1]{#1}
+% Only print in all on-line help
+\newcommand{\helponly}[1]{}
+
+% Ignore in LaTeX
+\newcommand{\latexignore}[1]{}
+% Only print in LaTeX
+\newcommand{\latexonly}[1]{#1}
+
+% Ignore in linear RTF
+\newcommand{\rtfignore}[1]{#1}
+% Only print in linear RTF
+\newcommand{\rtfonly}[1]{}
+
+% Ignore in WinHelp RTF
+\newcommand{\winhelpignore}[1]{#1}
+% Only print in WinHelp RTF
+\newcommand{\winhelponly}[1]{}
+
+% Ignore in wxHelp
+\newcommand{\xlpignore}[1]{#1}
+% Only print in wxHelp
+\newcommand{\xlponly}[1]{}
+
+% Ignore in HTML
+\newcommand{\htmlignore}[1]{#1}
+% Only print in HTML
+\newcommand{\htmlonly}[1]{}
+
+% Input a file only for help system (binder thickness is not a limitation
+% in help systems!)
+\newcommand{\helpinput}[1]{}
+
+\newcommand{\rtfsp}{ } % Force a space in RTF, ignore in Latex
+
+% =================== Miscellaneous macros ===================
+%
+% Headings consistent with generated ones
+\newcommand{\myheading}[1]{\vspace*{25pt}
+\begin{flushleft}
+{\LARGE \bf #1}
+\end{flushleft}
+\vskip 20pt
+}
+
+% Heading with entry in contents page.
+\newcommand{\chapterheading}[1]{\myheading{#1}
+\addcontentsline{toc}{chapter}{#1}}
+
+\newcommand{\sectionheading}[1]{\myheading{#1}
+\addcontentsline{toc}{section}{#1}}
+
+% Glossary environment
+\newenvironment{helpglossary}{\newpage\chapterheading{Glossary}\begin{description}}{\end{description}}
+
+% Glossary entry
+\newcommand{\gloss}[1]{\item[#1]\index{#1}}
+
+% Image: EPS in Latex, BMP or MF (whatever's available) in RTF. Requires psbox.
+\newcommand{\image}[2]{\psboxto(#1){#2}}
+
+% Image, left aligned (HTML)
+\newcommand{\imager}[2]{\psboxto(#1){#2}}
+
+% Image, right aligned (HTML)
+\newcommand{\imagel}[2]{\psboxto(#1){#2}}
+
+% Imagemap: principally for HTML only. In Latex,
+% acts like \image.
+\newcommand{\imagemap}[3]{\psboxto(#1){#2}}
+
+% Headers and footers
+% \setheader{EvenPageLeft}{EvenPageCentre}{EvenPageRight}
+% {OddPageLeft}{OddPageCentre}{OddPageRight}
+\newcommand{\setheader}[6]{
+\lhead[\fancyplain{}{#1}]{\fancyplain{}{#4}}
+\chead[\fancyplain{}{#2}]{\fancyplain{}{#5}}
+\rhead[\fancyplain{}{#3}]{\fancyplain{}{#6}}
+}
+
+% \setfooter{EvenPageLeft}{EvenPageCentre}{EvenPageRight}
+% {OddPageLeft}{OddPageCentre}{OddPageRight}
+\newcommand{\setfooter}[6]{
+\lfoot[\fancyplain{#1}{#1}]{\fancyplain{#4}{#4}}
+\cfoot[\fancyplain{#2}{#2}]{\fancyplain{#5}{#5}}
+\rfoot[\fancyplain{#3}{#3}]{\fancyplain{#6}{#6}}
+}
+
+% Needed for telling RTF where margin paragraph should go
+% in mirrored margins mode.
+\newcommand{\marginpareven}[1]{\hspace*{0pt}\marginpar{#1}}
+\newcommand{\marginparodd}[1]{\hspace*{0pt}\marginpar{#1}}
+
+% Environment for two-column table popular in WinHelp and manuals.
+\newcommand{\twocolwidtha}[1]{\def\twocolwidthaval{#1}}
+\newcommand{\twocolwidthb}[1]{\def\twocolwidthbval{#1}}
+\newcommand{\twocolspacing}[1]{\def\twocolspacingval{#1}}
+
+\twocolwidtha{3cm}
+\twocolwidthb{8.5cm}
+\twocolspacing{2}
+
+\newcommand{\twocolitem}[2]{#1 & #2\\}
+\newcommand{\twocolitemruled}[2]{#1 & #2\\\hline}
+
+\newenvironment{twocollist}{\renewcommand{\arraystretch}{\twocolspacingval}\begin{tabular}{lp{\twocolwidthbval}}}%
+{\end{tabular}\renewcommand{\arraystretch}{1}}
+
+% Specifying table rows for RTF compatibility
+\newcommand{\row}[1]{#1\\}
+
+% Use for the last ruled row for correct RTF generation.
+\newcommand{\ruledrow}[1]{#1\\\hline}
+
+% Indentation environment. Arg1 is left margin size
+\newenvironment{indented}[1]{\begin{list}{}{\leftmargin=#1}\item[]}%
+{\end{list}}
+
+% Framed box of text, normal formatting.
+\newcommand{\normalbox}[1]{\fbox{\vbox{#1}}}
+% Double-framed box of text.
+\newcommand{\normalboxd}[1]{\fbox{\fbox{\vbox{#1}}}}
+
+% WITHDRAWN -- can't do in RTF, easily.
+% Framed box of text, horizontally centred. Ragged right within box.
+% \newcommand{\centeredbox}[2]{\begin{center}\fbox{\parbox{#1}{\raggedright#2}}\end{center}}
+% Double-framed box of text, horizontally centred. Ragged right within box.
+% \newcommand{\centeredboxd}[2]{\begin{center}\fbox{\fbox{\parbox{#1}{\raggedright#2}}}\end{center}}
+
+% toocomplex environment: simply prints the argument in LaTeX,
+% comes out verbatim in all generated formats.
+\newenvironment{toocomplex}{}{}
+
+% Colour: dummy commands since LaTeX doesn't support colour.
+% \definecolour{name}{red}{blue}{green}
+% \fcol{name}{text} ; Foreground
+% \bcol{name}{text} ; Background
+\newcommand{\definecolour}[4]{}
+\newcommand{\definecolor}[4]{}
+\newcommand{\fcol}[2]{#2}
+\newcommand{\bcol}[2]{#2}
+\newcommand{\sethotspotcolour}[1]{}
+\newcommand{\sethotspotunderline}[1]{}
+\newcommand{\settransparency}[1]{}
+\newcommand{\backslashraw}[0]{}
+\newcommand{\lbraceraw}[0]{}
+\newcommand{\rbraceraw}[0]{}
+\newcommand{\registered}[0]{(r)}
+\newcommand{\background}[1]{}
+\newcommand{\textcolour}[1]{}
+\newcommand{\overview}[2]{See \helpref{#1}{#2}.}
+\newcommand{\docparam}[2]{{\it #1}\begin{list}{}{\leftmargin=1cm}\item[]
+#2%
+\end{list}}
+\newcommand{\wxheading}[1]{{\bf #1}}
+\newcommand{\const}[0]{{\bf const}}
+\newcommand{\constfunc}[3]{{\bf #1} {\bf #2}(#3) {\bf const}\index{#2}}
+\newcommand{\windowstyle}[1]{{\bf #1}\index{#1}}
+
+\addtolength{\textwidth}{1in}
+\addtolength{\oddsidemargin}{-0.5in}
+\addtolength{\topmargin}{-0.5in}
+\addtolength{\textheight}{1in}
+\sloppy
+
diff --git a/doc/verbatim.sty b/doc/verbatim.sty
new file mode 100644 (file)
index 0000000..462c329
--- /dev/null
@@ -0,0 +1,212 @@
+%% 
+%% This is file `verbatim.sty' generated
+%% on <1991/9/3> with the docstrip utility (v1.1l test). 
+%% 
+%% The original source file was `verbatim.doc'.
+%% 
+%% 
+%% Copyright (C) 1989,1990,1991 by Rainer Schoepf. All rights reserved. 
+%% 
+%% IMPORTANT NOTICE: 
+%% 
+%% You are not allowed to change this file. You may however copy this file 
+%% to a different name and then change this copy. 
+%% 
+%% You are allowed to distribute this file under the condition that it is 
+%% distributed together with all files mentioned in readme.mz4. If you 
+%% receive only some of these files from someone, complain! 
+%% 
+%% You are NOT ALLOWED to distribute this file alone. You are NOT ALLOWED 
+%% to take money for the distribution or use of this file (or a changed 
+%% version) except for some nominal charge for copying etc. 
+%% 
+%% Error Reports in case of UNCHANGED versions to 
+%% 
+%% Rainer Schoepf 
+%% Konrad-Zuse-Zentrum fuer Informationstechnik Berlin 
+%% Heilbronner Str. 10 
+%% W-1000 Berlin 31 
+%% Federal Republic of Germany 
+%% Internet: <SCHOEPF@SC.ZIB-Berlin.DE> 
+%% 
+\def\fileversion{v1.4f}
+\def\filedate{91/08/05}
+\def\docdate{91/08/05}
+
+%% \CheckSum{439}
+%% \CharacterTable
+%%  {Upper-case    \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
+%%   Lower-case    \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z
+%%   Digits        \0\1\2\3\4\5\6\7\8\9
+%%   Exclamation   \!     Double quote  \"     Hash (number) \#
+%%   Dollar        \$     Percent       \%     Ampersand     \&
+%%   Acute accent  \'     Left paren    \(     Right paren   \)
+%%   Asterisk      \*     Plus          \+     Comma         \,
+%%   Minus         \-     Point         \.     Solidus       \/
+%%   Colon         \:     Semicolon     \;     Less than     \<
+%%   Equals        \=     Greater than  \>     Question mark \?
+%%   Commercial at \@     Left bracket  \[     Backslash     \\
+%%   Right bracket \]     Circumflex    \^     Underscore    \_
+%%   Grave accent  \`     Left brace    \{     Vertical bar  \|
+%%   Right brace   \}     Tilde         \~}
+%%
+%% Style-option `verbatim' to use with LaTeX v2.09
+%% Copyright (C) 1989, 1990, 1991 by Rainer Sch\"opf, all rights reserved.
+\@ifundefined{verbatim@@@}{}{\endinput}
+\typeout{Style-Option: `verbatim'
+   \fileversion \space <\filedate>  (RmS)}
+\typeout{English Documentation
+   \@spaces \@spaces \space <\docdate>  (RmS)}
+\def\addto@hook#1#2{#1\expandafter{\the#1#2}}
+\newtoks\every@verbatim
+\every@verbatim={}
+\def\@makeother#1{\catcode`#112\relax}
+\begingroup
+ \catcode`\ =\active%
+\gdef\@vobeyspaces{\catcode`\ \active\let \@xobeysp}%
+\endgroup
+\def\@xobeysp{\leavevmode\penalty\@M\ }
+\newtoks\verbatim@line
+\def\verbatim@startline{\verbatim@line{}}
+\def\verbatim@addtoline#1{%
+  \verbatim@line\expandafter{\the\verbatim@line#1}}
+\def\verbatim@processline{\the\verbatim@line\par}
+\def\verbatim@finish{\ifcat$\the\verbatim@line$\else
+  \verbatim@processline\fi}
+\begingroup
+ \catcode`\`=\active
+ \gdef\verbatim@font{\tt \catcode96\active
+   \def`{\leavevmode\kern\z@\char96 }}
+\endgroup
+\def\@verbatim{\the\every@verbatim
+  \trivlist \item[]%
+  \leftskip\@totalleftmargin\rightskip\z@
+  \parindent\z@\parfillskip\@flushglue\parskip\z@
+  \@@par
+  \def\par{\leavevmode\null\@@par\penalty\interlinepenalty}%
+  \obeylines
+  \verbatim@font
+  \let\do\@makeother \dospecials}
+\def\verbatim{\@verbatim \frenchspacing\@vobeyspaces\verbatim@start}
+\@namedef{verbatim*}{\@verbatim\verbatim@start}
+\let\endverbatim=\endtrivlist
+\expandafter\let\csname endverbatim*\endcsname =\endtrivlist
+\def\comment{\@bsphack
+             \let\do\@makeother\dospecials\catcode`\^^M\active
+             \let\verbatim@startline\relax
+             \let\verbatim@addtoline\@gobble
+             \let\verbatim@processline\relax
+             \let\verbatim@finish\relax
+             \verbatim@}
+\let\endcomment=\@esphack
+\@ifundefined{vrb@catcodes}%
+  {\def\vrb@catcodes{%
+     \catcode`\!12\catcode`\[12\catcode`\]12}}{}
+\begingroup
+ \vrb@catcodes
+ \lccode`\!=`\\ \lccode`\[=`\{ \lccode`\]=`\}
+ \catcode`\~=\active \lccode`\~=`\^^M
+ \lccode`\C=`\C
+ \lowercase{%
+    \gdef\verbatim@start#1{%
+      \verbatim@startline
+      \if\noexpand#1\noexpand~%
+        \let\next\verbatim@
+      \else \def\next{\verbatim@#1}\fi
+      \next}%
+    \gdef\verbatim@#1~{\verbatim@@#1!end\@nil}%
+    \gdef\verbatim@@#1!end{%
+       \verbatim@addtoline{#1}%
+       \futurelet\next\verbatim@@@}%
+    \gdef\verbatim@@@#1\@nil{%
+       \ifx\next\@nil
+         \verbatim@processline
+         \verbatim@startline
+         \let\next\verbatim@
+       \else
+         \def\@tempa##1!end\@nil{\toks@{##1}}%
+           \@tempa#1\@nil
+         \@temptokena{!end}%
+         \edef\next{\noexpand\verbatim@test\the\toks@\noexpand~}%
+       \fi \next}%
+ \gdef\verbatim@test#1{%
+           \let\next\verbatim@test
+           \if\noexpand#1\noexpand~%
+             \expandafter\verbatim@addtoline
+               \expandafter{\the\@temptokena}%
+             \verbatim@processline
+             \verbatim@startline
+             \let\next\verbatim@
+           \else \if\noexpand#1
+             \@temptokena\expandafter{\the\@temptokena#1}%
+           \else \if\noexpand#1\noexpand[%
+             \let\@tempc\@empty
+             \let\next\verbatim@testend
+           \else
+             \expandafter\verbatim@addtoline
+               \expandafter{\the\@temptokena}%
+             \def\next{\verbatim@#1}%
+           \fi\fi\fi
+           \next}%
+    \gdef\verbatim@testend#1{%
+         \if\noexpand#1\noexpand~%
+           \expandafter\verbatim@addtoline
+             \expandafter{\the\@temptokena[}%
+           \expandafter\verbatim@addtoline
+             \expandafter{\@tempc}%
+           \verbatim@processline
+           \verbatim@startline
+           \let\next\verbatim@
+         \else\if\noexpand#1\noexpand]%
+           \let\next\verbatim@@testend
+         \else\if\noexpand#1\noexpand!%
+           \expandafter\verbatim@addtoline
+             \expandafter{\the\@temptokena[}%
+           \expandafter\verbatim@addtoline
+             \expandafter{\@tempc}%
+           \def\next{\verbatim@!}%
+         \else \expandafter\def\expandafter\@tempc\expandafter
+           {\@tempc#1}\fi\fi\fi
+         \next}%
+    \gdef\verbatim@@testend{%
+       \ifx\@tempc\@currenvir
+         \verbatim@finish
+         \edef\next{\noexpand\end{\@currenvir}%
+                    \noexpand\verbatim@rescan{\@currenvir}}%
+       \else
+         \expandafter\verbatim@addtoline
+           \expandafter{\the\@temptokena[}%
+           \expandafter\verbatim@addtoline
+             \expandafter{\@tempc]}%
+         \let\next\verbatim@
+       \fi
+       \next}%
+  \gdef\verbatim@rescan#1#2~{\if\noexpand~\noexpand#2~\else
+        \@warning{Characters dropped after `\string\end{#1}'}\fi}}
+\endgroup
+\def\verbatiminput{\begingroup
+  \@ifstar\sverbatim@input\verbatim@input}
+\def\sverbatim@input#1{\@verbatim
+  \@input{#1}\endtrivlist\endgroup\@doendpe}
+\def\verbatim@input#1{\@verbatim
+  \frenchspacing \@vobeyspaces
+  \@input{#1}\endtrivlist\endgroup\@doendpe}
+\begingroup
+  \lccode`\~=`\^^M
+  \lowercase{%
+    \gdef\verb{\begingroup
+      \verbatim@font
+      \catcode`\^^M\active
+      \def~{\endgroup\@latexerr{\string\verb\space command ended by
+                                end of line.}\@ehc}%
+    \let\do\@makeother \dospecials
+    \@ifstar\@sverb{\@vobeyspaces \frenchspacing \@sverb}}}
+\endgroup
+\def\@sverb#1{%
+  \catcode`#1\active
+  \lccode`\~`#1%
+  \lowercase{\let~\endgroup}%
+  \leavevmode\null}
+\endinput
+%% 
+%% End of file `verbatim.sty'.