summaryrefslogtreecommitdiff
path: root/macros/plain/contrib/samples/form.tex
blob: 2e32bc49f66adde9041f959b450b408989887bd8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
\magnification=1200
\def\YES{Y } \def\NO{N } \def\yes{y } \def\no{n }
\def\stripspace#1 \next{#1}
\message {Name of address file?}
\read-1 to\file
\openin1=\file
\newif\ifnotdone
\newdimen\longindentation \longindentation=4truein

\loop
\read1 to\address
\ifeof1 \notdonefalse \else \notdonetrue \fi
\ifnotdone
  % put here reads for all information needed for each letter
  % If you do not want a space after what is read in use the
  % command \edef\thing{\expandafter\stripspace\thing\next}
  % where \thing is the object you don't want the space after
  \read1 to\name
  \edef\name{\expandafter\stripspace\name\next}
  \input eetop
  \input date
  {\bigskip\leftskip=\longindentation \rm \today\bigskip\bigskip}
  {\leftskip=.6truein\rightskip=.6truein
  {\parskip=0pt\parindent=0pt\obeylines
  \address
  }
  \noindent Dear \name:\endgraf
  % Put body of letter here.  Put a \endgraf at the end of each 
  %    paragraph
  % if there are optional paragraphs add lines liek the following set
  % for each optional paragraph.  Make sure the included file has an 
  % \endgraf at the end of each of its paragraphs
  % \message{Include letter2 for \name?}
  % \read-1 to\answer
  % \ifx\answer\yes \input  letter2
   % \else \ifx\answer\YES \input letter2 \fi\fi
  {\parskip=0pt\obeylines
     {\nobreak\bigskip \leftskip=\longindentation Sincerely,
       \nobreak\bigskip\bigskip\bigskip % space for the signature
       W. B. Jones\endgraf
       Professor and Head
       {\endgraf\nobreak}}}
  \bigskip
  \noindent WBJ/jrn\endgraf
  }
  \input eebot
\repeat
\closein1
\end