% dph.sty

\typeout{ }
\typeout{------------dph.sty   13 june 1995-----------}

% useful definitions...
% d. huenemoerder 

\newcommand{\Header}[2]{
\pagestyle{myheadings}                   %%%%%%%%%%
\markboth{\bf \qquad #1 \hfill #2 \qquad}%%%%%%%%%%
         {\bf \qquad #1 \hfill #2 \qquad}%%%%%%%%%%
}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%     suppress badness messages %%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\tolerance=10000 \hbadness=10000 \vbadness=10000

%%% Suppress widows and orphans! %%%
\widowpenalty=1000 \clubpenalty=1000  

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% a hack for marginal comments.
% doesn't work in certain environments (like tabular)
% easily runs out of room if margins are small

\marginparwidth 1.0in    %% adjust size of margin to give room for remarks
\marginparsep 0.5em                            

\newcommand{\Skinny}{
  \textwidth=4in\textheight=8.5in
  \oddsidemargin=0.3in
  \evensidemargin=2in
  \marginparwidth 2.0in                           %% adjust size of margin to
  \marginparsep 0.2in                             %  give room for remarks
  }

%\newcommand{\Remark}[1]{\marginpar{\raggedright\scriptsize\sf #1}}
\newcommand{\Remark}[1]{\marginpar{\raggedright\scriptsize #1}}
\newcommand{\Note}[1]{\hfill\parbox{4in}{\small\sf#1}\\}

%%% testing:    hack to avoid overfull hboxes:
\newcommand{\Putline}{
  \advance\textwidth-26pt
  \rule{\the\textwidth}{1pt}
  \advance\textwidth+26pt
  }
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%


%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% \putstring{x}{y}{angle}{scale}{gray}{string}
% gray: 0=black, 1=white

\newcommand{\putstring}[6]{
\special{!userdict begin /bop-hook{gsave #1 #2 translate
#3 rotate /Times-Roman findfont #4 scalefont setfont
0 0 moveto #5 setgray (#6) show grestore}def end}
}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%


%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%    To change the margins of a document within the document,
%    modifying the parameters listed on page 163 will not work. They
%    can only be changed in the preamble of the document, i.e, before
%    the \begin{document} statement. To adjust the margins within a
%    document we define an environment which does it:
      \newenvironment{changemargin}[2]{\begin{list}{}{
         \setlength{\topsep}{0pt}\setlength{\leftmargin}{0pt}
         \setlength{\rightmargin}{0pt}
         \setlength{\listparindent}{\parindent}
         \setlength{\itemindent}{\parindent}
         \setlength{\parsep}{0pt plus 1pt}
         \addtolength{\leftmargin}{#1}\addtolength{\rightmargin}{#2}
         }\item }{\end{list}}
%    This environment takes two arguments, and will indent the left
%    and right margins by their values, respectively. Negative values
%    will cause the margins to be widened, so
%    \begin{changemargin}{-1cm}{-1cm} widens the left and right margins
%    by 1cm.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%



%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% figure macros:
% lmakefigure = label make figure
% lmakefiguresized = label make figure of size

% if you want bold-lined boxes around the figures uncomment the next 2
% variables, and swap comments in the ``epsfbox'' lines of the
% makefigure definitions.
%\fboxrule=2pt
%\fboxsep=1em

% need to modify makefigure macros to supply a parameter for the
% lst_entry in the caption command for the list of figures.  Until
% converted, add \lmakefigure and \lmakefiguresized
\newcommand{\lmakefigure}[4]{
% {file}{short caption}{long caption}{label}
  \begin{figure}[hbtp]
  \epsfxsize=4in
%  \centering\leavevmode{\fbox{\epsfbox{#1}}}
  \centering\leavevmode\epsfbox{#1}
%  \centering\leavevmode\BoxedEPSF{#1}   % for Mac
\caption[#2]{\small\it#3}
  \label{#4}
\end{figure}
}
\newcommand{\lmakefiguresized}[5]{
% {file}{short caption}{long caption}{label}{size}
  \begin{figure}[hbtp]
  \epsfxsize=#5
%  \centering\leavevmode{\fbox{\epsfbox{#1}}}
  \centering\leavevmode\epsfbox{#1}
%  \centering\leavevmode\BoxedEPSF{#1}   % for Mac
  \caption[#2]{{\small\it#3}}
  \label{#4}
\end{figure}
}


