2 %% This is file `epigraph.sty',
3 %% generated with the docstrip utility.
5 %% The original source files were:
7 %% epigraph.dtx (with options: `usc')
9 %% Author: Peter Wilson (CUA and NIST)
10 %% now at: peter.r.wilson@boeing.com
12 %% Copyright 1998 Peter R. Wilson
14 %% This program is provided under the terms of the
15 %% LaTeX Project Public License distributed from CTAN
16 %% archives in directory macros/latex/base/lppl.txt.
18 \NeedsTeXFormat{LaTeX2e
}
19 \ProvidesPackage{epigraph
}[1998/
11/
29 v1.1 typesetting epigraphs
]
20 \newlength{\beforeepigraphskip}
21 \setlength{\beforeepigraphskip}{.1\baselineskip}
22 \newlength{\afterepigraphskip}
23 \setlength{\afterepigraphskip}{.3\baselineskip}
24 \newlength{\epigraphwidth}
25 \setlength{\epigraphwidth}{.6\textwidth}
26 \newlength{\epigraphrule}
27 \setlength{\epigraphrule}{.4\p@
}
28 \newcommand{\epigraphsize}{\small}
29 \newcommand{\epigraphflush}{flushright
}
30 \newcommand{\textflush}{flushleft
}
31 \newcommand{\sourceflush}{flushright
}
32 %\newcommand{\@epirule}{\rule[.5ex]{\epigraphwidth}{\epigraphrule}}
33 \newcommand{\@epirule
}{\vspace{.5\baselineskip}}
34 \newcommand{\@epitext
}[1]{%
35 \begin{minipage
}{\epigraphwidth}\begin{\textflush} \textit{#1}\\
36 \ifdim\epigraphrule>
\z@ \@epirule
\else \vspace*
{1ex
} \fi
37 \end{\textflush}\end{minipage
}}
38 \newcommand{\@episource
}[1]{%
39 \begin{minipage
}{\epigraphwidth}\begin{\sourceflush} #1\end{\sourceflush}
41 \newcommand{\epigraph}[2]{\vspace{\beforeepigraphskip}
42 {\epigraphsize\begin{\epigraphflush}\begin{minipage
}{\epigraphwidth}
43 \@epitext
{#1}\\ \@episource
{#2}
44 \end{minipage
}\end{\epigraphflush}
45 \vspace{\afterepigraphskip}}}
46 \newcommand{\qitem}[2]{{\raggedright\item \begin{minipage
}{\epigraphwidth}
47 \@epitext
{#1}\\ \@episource
{#2}
49 \newcommand{\qitemlabel}[1]{\hfill}
50 \newenvironment{epigraphs
}{%
51 \vspace{\beforeepigraphskip}\begin{\epigraphflush}
53 \begin{minipage
}{\epigraphwidth}
55 {\itemindent\z@
\labelwidth\z@
\labelsep\z@
56 \leftmargin\z@
\rightmargin\z@
57 \let\makelabel\qitemlabel}}%
58 {\endlist\end{minipage
}\end{\epigraphflush}
59 \vspace{\afterepigraphskip}}
60 \newif\if@epirhs \@epirhstrue
61 \newif\if@epicenter \@epicentertrue
62 \newcommand{\@epipos
}{
63 \long\def\@ept
{flushleft
}
64 \ifx\epigraphflush\@ept
65 \@epirhsfalse \@epicenterfalse
67 \long\def\@ept
{center
}
68 \ifx\epigraphflush\@ept
69 \@epirhsfalse \@epicentertrue
71 \@epirhstrue \@epicenterfalse
74 \newcommand{\epigraphhead}[2][95]{%
75 \def\@epitemp
{\begin{minipage
}{\epigraphwidth}#2\end{minipage
}}
76 \def\ps@epigraph
{\let\@mkboth\@gobbletwo
79 \def\@oddhead
{\hfil\begin{picture
}(
0,
0)
80 \put(
0,-
#1)
{\makebox(
0,
0)
[r
]{\@epitemp
}}
84 \def\@oddhead
{\hfil\begin{picture
}(
0,
0)
85 \put(
0,-
#1)
{\makebox(
0,
0)
[b
]{\@epitemp
}}
88 \def\@oddhead
{\begin{picture
}(
0,
0)
89 \put(
0,-
#1)
{\makebox(
0,
0)
[l
]{\@epitemp
}}
93 \let\@evenhead\@oddhead
94 \def\@oddfoot
{\reset@font
\hfil\thepage\hfil}
95 \let\@evenfoot\@oddfoot
}
96 \thispagestyle{epigraph
}}
99 %% End of file `epigraph.sty'.