% LaTeX customization
 
 
\makeatletter				% for a little while
 
\def\inputverbatim#1{%
\begingroup \catcode``=13 \@noligs \tt \let\do\@makeother \dospecials
\obeylines \obeyspaces \frenchspacing \input #1 \endgroup }
 
% plain TeX compatibility
 
\def\oldstyle{\xdef\@oldstyle{\the\textfont\@ne}\mit\@oldstyle}
 
 
% PhD-TeX compatibility
 
\def\showsummary{%
    \begingroup
	\def\note##1{%
	    \ifcase\value{##1}no ##1s\or
		1 ##1\else
		\the\value{##1} ##1s\fi
	}%
	\typeout{LaTeX summary: \note{figure}, \note{table}, \note{footnote}.}%
    \endgroup
}
 
\def\smaller{\footnotesize}
 
 
% Float Support
 
\def\topfraction{0.85}
\def\textfraction{0.20}
\def\floatpagefraction{0.85}
\def\dbltopfraction{0.85}
\def\dblfloatpagefraction{0.85}
 
 
% \tagfigure*[FLOAT]{FILE}{CAPTION}{LABEL}
%    *		optional
%    FLOAT	float options
%    FILE	reads TPIC output in file figureFILE
%    CAPTION	for list of figures
%    LABEL	for \ref and \pageref
\def\tagfigure{\@ifstar{\@stagfigure}{\@tagfigure}}
\def\@tagfigure{\@ifnextchar[{\@@tagfigure}{\@@tagfigure[t]}}
\def\@stagfigure{\@ifnextchar[{\@@stagfigure}{\@@stagfigure[t]}}
 
\def\@@tagfigure[#1]#2{%
    \@@@tagfigure[#1]{\input figure#2\relax\centerline{\box\graph}}}
\def\@@stagfigure[#1]#2{%
    \@@@stagfigure[#1]{\input figure#2\relax\centerline{\box\graph}}}
 
 
% \tagdiagram*[FLOAT]{FILE}{CAPTION}{LABEL}
%    *		optional
%    FLOAT	float options
%    FILE	reads LaTeX input in file diagramFILE
%    CAPTION	for list of figures
%    LABEL	for \ref and \pageref
\def\tagdiagram{\@ifstar{\@stagdiagram}{\@tagdiagram}}
\def\@tagdiagram{\@ifnextchar[{\@@tagdiagram}{\@@tagdiagram[t]}}
\def\@stagdiagram{\@ifnextchar[{\@@stagdiagram}{\@@stagdiagram[t]}}
 
\def\@@tagdiagram[#1]#2{\@@@tagfigure[#1]{\input diagram#2\relax}}
\def\@@stagdiagram[#1]#2{\@@@stagfigure[#1]{\input diagram#2\relax}}
 
 
% \tagverbatim*[FLOAT]{FILE}{CAPTION}{LABEL}
%    *		optional
%    FLOAT	float options
%    FILE	reads LaTeX input in file FILE and inserts in in verbatim mode.
%    CAPTION	for list of figures
%    LABEL	for \ref and \pageref
\def\tagverbatim{\@ifstar{\@stagverbatim}{\@tagverbatim}}
\def\@tagverbatim{\@ifnextchar[{\@@tagverbatim}{\@@tagverbatim[t]}}
\def\@stagverbatim{\@ifnextchar[{\@@stagverbatim}{\@@stagverbatim[t]}}
 
\def\@@tagverbatim[#1]#2{\@@@tagfigure[#1]{\inputverbatim{#2}}}
\def\@@stagverbatim[#1]#2{\@@@stagfigure[#1]{\inputverbatim{#2}}}
 
 
\def\@@@tagfigure[#1]#2#3#4{%
    \begin{figure}[#1]
	\hrule
	\vskip .5\baselineskip
	\begin{minipage}\columnwidth
	    \small#2%
	\end{minipage}
	\vskip .5\baselineskip plus .5\baselineskip
	\begingroup
	    \setbox\z@=\hbox{#4}%
	    \ifdim\wd\z@>\z@
		\caption{#3}%
		\label{#4}%
	    \else
		\captcont{#3}%
	    \fi
	\endgroup
	\vskip 2pt
	\hrule
    \end{figure}
}
 
\def\@@@stagfigure[#1]#2#3#4{%
    \begin{figure*}[#1]
	\hrule
	\vskip .5\baselineskip
	\begin{minipage}\textwidth
	    \small#2%
	\end{minipage}
	\vskip .5\baselineskip plus .5\baselineskip
	\begingroup
	    \setbox\z@=\hbox{#4}%
	    \ifdim\wd\z@>\z@
		\caption{#3}%
		\label{#4}%
	    \else
		\captcont{#3}%
	    \fi
	\endgroup
	\vskip 2pt
	\hrule
    \end{figure*}
}
 
 
% \tagtable*[FLOAT]{FILE}{CAPTION}{LABEL}
%    *		optional
%    FILE	read LaTeX input in file tableFILE
%    FLOAT	float options
%    CAPTION	for list of tables
%    LABEL	for \ref and \pageref
\def\tagtable{\@ifstar{\@stagtable}{\@tagtable}}
\def\@tagtable{\@ifnextchar[{\@@tagtable}{\@@tagtable[t]}}
\def\@stagtable{\@ifnextchar[{\@@stagtable}{\@@stagtable[t]}}
 
\def\@@tagtable[#1]#2#3#4{%
    \begin{table}[#1]
	\hrule
	\vskip .5\baselineskip
	\begin{minipage}\textwidth
	    \small\input table#2\relax
	\end{minipage}
	\vskip .5\baselineskip plus .5\baselineskip
	\begingroup
	    \setbox\z@=\hbox{#4}%
	    \ifdim\wd\z@>\z@
		\caption{#3}%
		\label{#4}%
	    \else
		\captcont{#3}%
	    \fi
	\endgroup
	\vskip 2pt
	\hrule
    \end{table}
}
 
\def\@@stagtable[#1]#2#3#4{%
    \begin{table*}[#1]
	\hrule
	\vskip .5\baselineskip
	\begin{minipage}\columnwidth
	    \small\input table#2\relax
	\end{minipage}
	\vskip .5\baselineskip plus .5\baselineskip
	\begingroup
	    \setbox\z@=\hbox{#4}%
	    \ifdim\wd\z@>\z@
		\caption{#3}%
		\label{#4}%
	    \else
		\captcont{#3}%
	    \fi
	\endgroup
	\vskip 2pt
	\hrule
    \end{table*}
}
 
 
% Environments:
 
% DESCRIBE - similar to DESCRIPTION, but indents extra on left margin of
%	outer list
 
\def\describe{\list{}{\labelwidth\z@ \itemindent-\leftmargin
	\ifnum\@listdepth=1 \advance\leftmargin by2em\fi
	\let\makelabel\descriptionlabel}}
\let\enddescribe=\endlist
 
 
% Document style options:
%	     10pt - Makes ten-point type the normal (default) type size
%	draftnote - Customized draft option
 
\@namedef{ds@10pt}{\def\@ptsize{0}}	%%% for orthogonality
 
 
\newif\ifdraft	\draftfalse
 
\def\draftstring{{\ifdraft \tt Draft\fi}}
 
\def\draftext{%
    \ifdraft
	\begingroup
	    \tt
	    \ifodd\c@page
		\LaTeX set \today\ with \fmtname\ v\fmtversion
	    \else
		Draft \versiontag/ of \versiondate/
	    \fi
	\endgroup
    \fi
}
 
\def\ds@draftnote{%
    \drafttrue
    \@ifundefined{ds@draft}{}{\ds@draft}%
    \def\ps@plain{%
	\let\@mkboth=\@gobbletwo
	\def\@oddhead{\draftext\hfil}%
	\def\@oddfoot{\draftstring\hfil\rm\thepage\hfil\draftstring}%
	\def\@evenhead{\hfil\draftext}%
	\let\@evenfoot=\@oddfoot
    }%
    \let\ps@@headings=\ps@headings
    \def\ps@headings{%
	\ps@@headings
	\def\@oddfoot{\draftext\hfil}%
	\def\@evenfoot{\hfil\draftext}%
     }%
}
 
 
% Page Styles
 
% \pagestyle{myfootings} similar to the myheadings command but also permits
% the user to define foot information as well as head information
%	\markleftfoot{left_foot}	specifies the foot for odd-numbered
%					pages
%	\markrightfoot{right_foot}	specifies the foot for even-numbered
%					pages
% N.B.	DOES NOT USE MARKS TO ACCOMPLISH THIS, OWING TO CONFLICT WITH HEADING
%	ROUTINES
 
\def\ps@myfootings{\ps@myheadings}
 
\def\markleftfoot#1{\def\@evenfoot{\hbox{}\sl#1\hfil}}
\def\markrightfoot#1{\def\@oddfoot{\hfil\sl#1\hbox{}}}
 
 
% \pagestyle{reprint} similar to plain page style in draft mode
 
\let\reprintext=\draftext
\let\reprintstring=\draftstring
 
\def\ps@reprint{%
    \def\draftext{%
	\ifdraft
	    \begingroup
		\tt
		\ifodd\c@page
		    \LaTeX set \today
		\else
		    Draft \versiontag/
		\fi
	    \endgroup
	\fi
    }%
    \def\@oddhead{\reprintext\hfil\draftext}%
    \def\@oddfoot{\reprintstring\hfil\rm\thepage}%
    \def\@evenhead{\draftext\hfil\reprintext}%
    \def\@evenfoot{\rm\thepage\hfil\reprintstring}%
}
 
 
% The Title
 
\def\title#1{%
    \gdef\@title{#1}%
    \gdef\banner{%
	\newpage\setcounter{page}{1}%
	\begin{center}\Large#1\end{center}%
    }%
}
 
 
% Miscellany
 
\def\implies{\quad\supset\ }
 
\def\tdots{\ldots\thinspace}
 
\def\boxit#1{\fbox{\sc#1}}
 
\def\note#1{\ifdraft\marginpar{\tt#1}\fi}
 
 
% Fractions (from The TUGboat v6 n1, 1985)
 
\def\myfrac#1/#2{%
    \leavevmode\kern.1em
    \raise.5ex\mbox{\the\scriptfont\z@ #1}\kern-.1em
    /\kern-.15em\lower.25ex\mbox{\the\scriptfont\z@ #2}%
}
 
 
% Trademarks...
 
\input trademark.sty
 
 
% Continuation Captions...
 
\input captcont.sty
 
 
% Startup
 
\xdef\today{%
    \ifcase\month
	\number\month\or
	January\or February\or March\or April\or May\or June\or
	July\or August\or September\or October\or November\or December\else
	\number\month\fi
    \space\number\day, {\noexpand\mit\number\year}%
}
 
\begingroup
    \count0=\time
    \count1=\count0
    \divide\count0 by 60
    \count2=\count0
    \multiply\count0 by 60
    \advance\count1 by -\count0
    \ifnum\count2>11
	\ifnum\count2>12 \advance\count2 by -12\fi
	\def\ampm{pm}%
    \else
	\ifnum\count2=0 \advance\count2 by 12\fi
	\def\ampm{am}%
    \fi
    \xdef\daytime{%
	\ifnum\count2<10 0\fi \the\count2:%
	\ifnum\count1<10 0\fi \the\count1
	\ampm
    }%
\endgroup
 
 
\makeatother				% back to normal
 
%
%Mail-From: BEEBE created at  3-Dec-86 11:41:39
%Date: Wed 3 Dec 86 11:41:39-MST
%From: "Nelson H.F. Beebe" <Beebe@UTAH-SCIENCE.ARPA>
%Subject: Funny behaviour of itemize with long item keys
%To: jrp%nplpsg%uucp@CS.UCL.AC.UK
%cc: BEEBE@UTAH-SCIENCE.ARPA
%X-US-Mail: "Center for Scientific Computation, South Physics,
%University of Utah, Salt Lake City, UT 84112"
%X-Telephone: (801) 581-5254
%Message-ID: <12259892637.20.BEEBE@UTAH-SCIENCE.ARPA>
%ReSent-Date: Wed 3 Dec 86 16:31:14-MST
%ReSent-From: "Nelson H.F. Beebe" <Beebe@UTAH-SCIENCE.ARPA>
%ReSent-To: jrp%nplpsg%uucp@SEISMO.CSS.GOV
%ReSent-Message-ID: <12259945355.20.BEEBE@UTAH-SCIENCE.ARPA>
%
%In TeXHaX #10 you ask for a solution for the itemize
%environment where long keys do not cause a line break, when
%they would look nicer if they did.
%
%I met this problem in writing my TECO manual, and here is my
%solution.  First, I have two environments:
%
%% ======================================================================
%% commandtable generates a list with the item entered into the index
%% and the item label flush left in \tt font.  It is intended for
%% documenting TECO commands.
%\newcommand{\tablelabel}[1]{\mbox{\tt#1}\hfil\INDEX{{\string\tt\space #1}}{#1}}
%\newenvironment{commandtable}{
%    \begin{list}{}
%    {
%      \let\makelabel\tablelabel
%      \setlength{\labelwidth}{30pt}
%      \setlength{\leftmargin}{1.1\labelwidth}
%    }
%  }{\end{list}}
%
%% ======================================================================
%% commandentry generates a list with the item label flush left in \sf
%% font.  It is intended for the TECO command descriptions.
%
%\newcommand{\entrylabel}[1]{\mbox{\sf#1:}\hfil}
%\newenvironment{commandentry}{
%    \begin{list}{}
%    {
%      \let\makelabel\entrylabel
%      \setlength{\labelwidth}{40pt}
%      \setlength{\leftmargin}{1.1\labelwidth}
%    }
%  }{\end{list}}
%
%Then I have a newline macro:
%\newcommand{\NEWLINE}{\mbox{}\\ \vspace*{-\baselineskip}}
%
%Here is how they are used:
% \begin{commandtable}
% \item[\protect\CTL{\BS{}}]\NEWLINE{}
%	\begin{commandentry}
%        \item[Action]
%		Returns from a function.  If issued at top-level,
%		the interpreter simply terminates, just as if
%		end of input had been reached.
%        \item[Errors]
%		None.
%        \item[Return values]
%		Any arguments in effect are passed back to the
%		caller.
%        \end{commandentry}
% ...etc...
% \end{commandtable}
%
%The other two macros listed are unimportant, but here they are:
%\newcommand{\BS}{{\tt\symbol{92}}}      % ASCII backslash
%\newcommand{\NEWLINE}{\mbox{}\\ \vspace*{-\baselineskip}}
