Debian Codegraph @

texmf-dist/doc/latex/coffeestains/coffeestains-en.tex

raw
1 \documentclass[a4paper, 11pt, BCOR = 0 pt, oneside, english]{scrartcl}
2 \usepackage{tikz}
3 \usepackage{fancyvrb}
4 \usetikzlibrary{arrows, shapes}
5 \usepackage[light, largesmallcaps]{kpfonts}
6 \usepackage{coffeestains}
7 \usepackage[useregional]{datetime2}
8 \usepackage{gitinfo2}
9 \usepackage{scrlayer-scrpage}
10 \usepackage{tcolorbox}
11 \usepackage{varioref}
12 \usepackage[english]{babel}
13 \author{Patrick Bideault}
14 \usepackage{hyperref}
15 \hypersetup{
16 pdftitle = LaTeX Coffee Stains,
17 colorlinks,
18 linkcolor={brown!60!black},
19 citecolor={brown!60!black},
20 urlcolor={brown!60!black}
21 }
22 \ifoot{\textsf{\textcolor{lightgray}{version \gitRel{} -- \DTMtoday}
23 }}
24 \cfoot{}
25 \ofoot{\textsf{\thepage}}
26
27 \begin{document}
28
29 \title{LaTeX Coffee Stains}
30 \author{a package by Hanno Rein\\
31 maintained by Patrick Bideault\\
32 \texttt{[email protected]}\\
33 ~\\
34 \url{https://framagit.org/Pathe/coffeestains}}
35 \renewcommand{\today}{version \gitRel{} -- \DTMtoday{}}
36 \maketitle
37
38 \coffeestainA{0.9}{0.85}{-25}{5cm}{1.3cm}
39 \label{stainA}
40 \section{Introduction}
41 This package provides an essential feature to \LaTeX~that has been missing for
42 too long. It adds a coffee stain to your documents. A lot of time can be saved
43 by printing stains directly on the page rather than adding them manually. You can
44 choose from four different stain types:
45 \begin{itemize}
46 \item[A.] $270^\circ$ circle stain with two tiny splashes, like \vpageref{stainA}
47 \item[B.] $60^\circ$ circle stain, as \vpageref{stainB}
48 \item[C.] two splashes with light colours, as \vpageref{stainC}
49 \item[D.] and a colourful twin splash, as \vpageref{stainD}
50 \end{itemize}
51
52 \section{Usage}
53 To use the package, simply place the \texttt{coffeestains.sty} file in the directory with all of your
54 other \texttt{.tex} files \textit{or} install it properly (consult your distribution's manual).
55 Then include the following line in the header of your document:
56 \begin{verbatim}
57 \usepackage{coffeestains}
58 \end{verbatim}
59
60 \vfill{}
61
62 \begin{tcolorbox}
63 The command used for the above coffee stain is
64
65 \verb|\coffeestainA{0.9}{0.85}{-25}{5cm}{1.3cm}|
66 \end{tcolorbox}
67 \newpage{}
68 \coffeestainB{0.7}{1}{-30}{18 pt}{-135 pt}
69 \label{stainB}
70
71 To place a coffee stain on a page, put one of the following commands in the source code of the relevant page:
72 \begin{verbatim}
73 \coffeestainA{alpha}{scale}{angle}{xoff}{yoff}
74 \coffeestainB{alpha}{scale}{angle}{xoff}{yoff}
75 \coffeestainC{alpha}{scale}{angle}{xoff}{yoff}
76 \coffeestainD{alpha}{scale}{angle}{xoff}{yoff}
77 \end{verbatim}
78
79 \begin{itemize}
80 \item \texttt{alpha} is the transparency factor $\in [0,1]$;
81 \item \texttt{scale} is the scale factor, and the standard is \texttt{scale}=1;
82 \item \texttt{angle} is the angle of the stain, relative to its center. It is in
83 degrees $\in [0,360]$;
84 \item the position relative to the centre of the page is given by x and
85 y offsets \texttt{xoff} and \texttt{yoff}. It is advisable to specify
86 a measurement unit.
87 \end{itemize}
88
89
90 \section{Copyright}
91 You can freely distribute this package as we do not believe in imaginary
92 property. All stains were self-made, photographed by Hanno Rein, processed with gimp
93 and traced with Inkscape. Donations should be made in coffee only to
94 \begin{quote}
95 Hanno Rein\\
96 University of Toronto at Scarborough\\
97 DPES Physics and Astrophysics\\
98 1265 Military Trail\\
99 Toronto, Ontario M1C 1A4\\
100 Canada
101 \end{quote}
102
103 \section{Desired improvements}
104 This package obviously helps, but many stains are still manually added to
105 documents: latte stains, tea stains, gazpacho stains\dots{} they all should be
106 printed in the future.
107
108 And our efforts shall go beyond the liquid stains: how many documents get their
109 grease stains manually printed in repair shops? The \LaTeX{} community shall
110 address this issue and create the adequate tools.
111
112 \vfill{}
113
114 \begin{tcolorbox}
115 The command used for the above coffee stain is
116
117 \verb|\coffeestainB{0.7}{1}{-30}{18 pt}{-135 pt}|
118 \end{tcolorbox}
119 \newpage{}
120 \section{Change Log}
121 \begin{itemize}
122 \item April 3, 2009: initial coffee stain by Hanno Rein. This version is still
123 available at \url{http://legacy.hanno-rein.de/hanno-rein.de/archives/349}. In the actual git repository, this version is now tagged 0.1.
124 \item November 23, 2010: \texttt{coffee2.sty}, an improved version that works
125 with pdflatex. Thanks to \href{http://www.sultanik.com/}{Evan Sultanik}! This
126 version is now tagged 0.2.
127 \item March 24, 2011: \texttt{coffee3}, another improved version that works with
128 pdflatex and allows you to scale, rotate and change the transparency of any
129 coffee stain. Thanks to \href{http://pcmap.unizar.es/~pilar/}{Professor Luis
130 Randez}! This version is now tagged 0.3.
131 \item May 25, 2012: \texttt{coffee4}, an improved version by
132 \href{http://nepsweb.co.uk/homeapr/}{Adrian Robson}, who writes: “I find
133 I rarely manage to put my coffee mug down exacly in the middle of my papers.
134 So I have amended coffee3.sty to support off centre coffee stains.” This
135 version is now tagged 0.4.
136 \item May 1, 2021: the \texttt{coffeestains} package on a git repository. The
137 rotation of the stains is now relative to the centre of the stain itself, not
138 anymore to the centre of the page. Version 0.5 by Patrick Bideault.
139 \end{itemize}
140 \coffeestainC{1}{1}{180}{0}{-5 mm}
141 \label{stainC}
142
143 \section{Eternal mottos}
144
145 Coffee is great.
146
147 \vspace{5mm}
148
149 \noindent
150 Coffee will save the world.
151
152 \vfill{}
153
154 \begin{tcolorbox}
155 The command used for the above coffee stain is
156
157 \verb|\coffeestainC{1}{1}{180}{0}{-5 mm}|
158 \end{tcolorbox}
159
160 \begin{tcolorbox}
161 The command used for the coffee stain on the next page is
162
163 \verb|\coffeestainD{0.4}{0.5}{90}{3 cm}{4 cm}|
164 \end{tcolorbox}
165
166 \newpage{}
167 \pagestyle{empty}
168 ~\\
169
170 \coffeestainD{0.4}{0.5}{90}{3 cm}{4 cm}
171 \label{stainD}
172
173 \vfill{}
174 \begin{center}
175 \textsc{This page was intentionally left blank}
176
177 but we had to ruin it by letting you know.
178 \end{center}
179
180 \vfill{}
181 \end{document}