%------------- Macros for making figures --------------------
% July 7, 1993
% This version of the figures style sheet is designed to be
% scale-independent.  
%
\input{epsf.sty}
%

%%
%%
%%

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%
%% \putpsfigure places a Postscript figure at the center 
%%            of the current LaTeX picture environment.
%%

\newcommand\putpsfigure[1]{\put(0,0){\makebox(0,0){\epsffile{#1}}}}


%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%
%% \puttext places text centered at a point in the LateX
%%          picture environment
%%

\newcommand\puttext[2]{\put(#1){\makebox(0,0){#2}}}


%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%  PSFIGURE:    LaTeX picture-like environment for
%%               labeling Postscript figures.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%
\newdimen\myunitlength
%%
\newenvironment{psfigure}[3]{%%
\myunitlength = #2            %% make unit length 0.01 picture height
\divide\myunitlength by 100%%   
\setlength\unitlength{\myunitlength}%% 
\begin{minipage}[t]{#1}%%          %% set width of minipage to psfigure width
\begin{center}%%
\begin{picture}(10,100)(-5,-50)
\epsfysize #2%%               %% scale Postscript figure to psfigure height
\putpsfigure{#3}%%
}{\end{picture}%%
\end{center}%%
\end{minipage}%%
}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Example:
%%           \begin{psfigure}{4in}{2in}{fig.ps}
%%           \end{psfigure}
%%
%% inserts the postscript figure ``fig.ps'' scaled to a height
%% of 2 inches and centered within a LaTeX picture
%% environment with unitlength of 0.01 * 4in.
%% The picture environment is in turn centered in a minipage environment
%% of width 4 inches.
%%
%% While in the psfigure environment, LaTeX picture commands are
%% in effect. With picture coordinates (x,y) with in the range
%%  -50<y<50.  The range of the x coordinate can be calculated
%% from the width and height values used when the command is called.
%% In the example, -100<x<100 since the width is twice the height.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
%  Make a  ``cross-hair''
%
\newcommand\putcrosshair[1]{\put(#1){
             \put(0,-50){\line(0,1){100}}
             \put(-50,0){\line(1,0){100}}
             \multiput(0,-2.5)(10,0){6}{\line(0,1){5}}
             \multiput(0,-2.5)(-10,0){6}{\line(0,1){5}}
             \multiput(-2.5,0)(0,10){6}{\line(1,0){5}}
             \multiput(-2.5,0)(0,-10){6}{\line(1,0){5}}
             \multiput(0,-1)(1,0){50}{\line(0,1){2}}
             \multiput(0,-1)(-1,0){50}{\line(0,1){2}}
             \multiput(-1,0)(0,1){50}{\line(1,0){2}}
             \multiput(-1,0)(0,-1){50}{\line(1,0){2}}
         }}



%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%
%%
%%
\newenvironment{rightindent}[1]{\noindent\begin{minipage}[b]{#1}
\setlength{\parindent}{20pt}}{\end{minipage}}


\newcommand\myindent{\hspace{20pt}}

%%%%%%%%%%end of file %%%%%%%%%%%%%%%%%%%%
