Skip to content
Permalink
master
Go to file
 
 
Cannot retrieve contributors at this time
134 lines (112 sloc) 4.84 KB
% This is the UCONN letterhead class. It can be used in
% conjunction with LaTeX, and the appropriate insignia files,
% to produce a fair reproduction of the UCONN letterhead style.
% Have a look at instructions.pdf for more guidance.
% Copyright (C) 2014 Alexander Russell, acr@cse.uconn.edu
% This program is free software can redistribute it and/or
% modify it under the terms of the GNU General Public License as
% published by the Free Software Foundation; either version 2 of the
% License, or (at your option) any later version.
% This program is distributed in the hope that it will be useful, but
% WITHOUT ANY WARRANTY; without even the implied warranty of
% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
% General Public License for more details.
% You should have received a copy of the GNU General Public License
% along with this program; if not, write to the Free Software
% Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
% USA
\NeedsTeXFormat{LaTeX2e}
\ProvidesClass{uconnletter}[2016/01/04 UCONN Letterhead]
\RequirePackage{graphicx}
\RequirePackage{xcolor}
\RequirePackage{adjustbox}
\RequirePackage{pbox}
\DeclareOption*{\PassOptionsToClass{\CurrentOption}{letter}}
\ProcessOptions\relax
\LoadClass[letterpaper]{letter}
% Setup UCONN official letterhead colors.
\definecolor{UConnBlue}{cmyk}{.97,.76,.12,.70}
\definecolor{UConnGray}{cmyk}{.33,.18,.13,.40}
% Setup UCONN logo.
\newlength{\ucl@logoheight}
\setlength{\ucl@logoheight}{.62in}
\newcommand{\uclogo}{\includegraphics[height=\ucl@logoheight]{uconn-wordmark-stacked-blue-gray}}
% Initialize properties to default value
\newcommand{\ucl@school}{\@empty}
\newcommand{\ucl@department}{\@empty}
\newcommand{\ucl@name}{\@empty}
\newcommand{\ucl@title}{\@empty}
\newcommand{\ucl@addressa}{\@empty}
\newcommand{\ucl@addressb}{\@empty}
\newcommand{\ucl@phone}{\@empty}
\newcommand{\ucl@fax}{\@empty}
\newcommand{\ucl@web}{\@empty}
%%% The rest of this part establises the hooks for the \tocdetails command.
\define@key{ucl@inside}{school}{\renewcommand{\ucl@school}{#1}}
\define@key{ucl@inside}{office}{\renewcommand{\ucl@school}{#1}}
\define@key{ucl@inside}{department}{\renewcommand{\ucl@department}{#1}}
\define@key{ucl@inside}{name}{\renewcommand{\ucl@name}{#1}}
\define@key{ucl@inside}{title}{\renewcommand{\ucl@title}{#1}}
\define@key{ucl@inside}{addressa}{\renewcommand{\ucl@addressa}{#1}}
\define@key{ucl@inside}{addressb}{\renewcommand{\ucl@addressb}{#1}}
\define@key{ucl@inside}{phone}{\renewcommand{\ucl@phone}{#1}}
\define@key{ucl@inside}{fax}{\renewcommand{\ucl@fax}{#1}}
\define@key{ucl@inside}{web}{\renewcommand{\ucl@web}{#1}}
\newcommand{\letterdata}[1]{\setkeys{ucl@inside}{#1}}
% Remove the \address command--we already have the return address in the header.
\renewcommand{\address}[1]{}
% Setup header and footer components.
\newlength{\ucl@headerheight}
\setlength{\ucl@headerheight}{.65in}
\newsavebox\ucl@headeraddressblockbox
\newcommand{\ucl@headeraddressblock}{%
\textcolor{UConnGray}{\vrule}\hspace{5pt}\fontsize{8}{10}\pbox[t]{2.5in}{%
\usefont{OT1}{phv}{m}{n}\textcolor{UConnBlue}{\ucl@school}\\
\usefont{OT1}{phv}{b}{n}\textcolor{UConnBlue}{\ucl@department}\\[1pt]
\usefont{OT1}{phv}{b}{n}\textcolor{UConnGray}{\ucl@name}\\
\usefont{OT1}{phv}{m}{n}\textcolor{UConnGray}{\ucl@title}}}
\newcommand{\ucl@firstpageheader}{%
\begin{minipage}[b][\ucl@headerheight][t]{\textwidth}
\adjustbox{valign=T,set height=0pt}{\uclogo}%
\hfill%
\adjustbox{valign=T,set height=0pt}{\ucl@headeraddressblock}
\end{minipage}}
\newcommand{\ucl@footeraddressblock}{%
\begin{minipage}[b]{4in}
\fontsize{7}{10}\usefont{OT1}{phv}{m}{n}%
\textcolor{UConnGray}{\ucl@addressa}\\
\textcolor{UConnGray}{\ucl@addressb}\\
\textcolor{UConnGray}{\textsc{phone} \ucl@phone}\\
\textcolor{UConnGray}{\textsc{fax} \ucl@fax}\\
\textcolor{UConnGray}{\ucl@web}
\end{minipage}}
\newcommand{\ucl@equalopportunity}{\fontsize{5.5}{6.5}\usefont{OT1}{phv}{m}{n}%
\textcolor{UConnGray}{\textit{An Equal Opportunity Employer}}}
\newcommand{\ucl@footer}{%
\begin{minipage}{\textwidth}
\ucl@footeraddressblock \hfill \ucl@equalopportunity
\end{minipage}}
\setlength{\hoffset}{0in}
\setlength{\topmargin}{-.3125in}
\setlength{\headheight}{\ucl@headerheight}
\setlength{\headsep}{.5in}
\setlength{\footskip}{.65in}
\setlength{\textwidth}{6.5in}
\setlength{\textheight}{7.7in}
\setlength{\evensidemargin}{0in}
\setlength{\oddsidemargin}{0in}
% Set up the first page style.
\renewcommand{\ps@firstpage}{%
\renewcommand{\@oddhead}{\ucl@firstpageheader}%
\renewcommand{\@oddfoot}{\ucl@footer}%
}
% Set up the 2ff. page style.
\renewcommand{\ps@plain}{%
\renewcommand{\@oddhead}\@empty%
\renewcommand{\@evenhead}\@empty%
\renewcommand{\@oddfoot}{\ucl@footer}%
\renewcommand{\@evenfoot}{\ucl@footer}%
}
\pagestyle{plain}
\thispagestyle{firstpage}
\AtBeginDocument{\signature{\ucl@name}}
You can’t perform that action at this time.