\ifx\mycolourloaded\relax\endinput\else\let\mycolourloaded=\relax\fi

% my-colour.tex V 1.2
% Jim Diamond <jim.diamond@acadiau.ca>

% Implement colour for plain tex using miniltx.tex, color.sty and
% code from pdfcolor.tex.
%
% pdfcolor.tex redefines \makeheadline and \makefootline to do The
% Right Thing (namely, print out these lines in the foreground
% colour), but these definitions are incompatible with those from
% color.sty, which provides more features and flexibility.  Thus
% include the useful things from pdfcolor.tex, \input the other
% files, and add a few macros to do everything we want.

% After having input this file, use something of the form
%	\pagecolor{blue}
% to set the background colour,
%	\color{red}
% to set the foreground colour, and lines like
%	\definecolor{cyan}{cmyk}{1,0,0,0}
% or
%	\definecolor{blue}{rgb}{0,0,1}
% to define new colours.

% Use
%	\headfootcolour{some_colour}
% to define the colour used in the header and footer lines.

% Modification history
% 20071112 V 1.1 Remove \pagecolor{white} and \color{black} since these were,
%		 apparently, there to over-ride XDvi resources I used to have
%		 which set the foreground to white and the background to black.
%		 Duh.
% 20080105 V 1.2 Rationalize macro names a tiny bit:
%                - macros whose only purpose is to store a colour name
%                  have no "u"
%                - *my* other colour-related macros have "u"s
%                - see slides5.sty (and maybe later) for more
%                  extensive collections of colour-related macros.


\input miniltx

\makeatletter

\ifpdf
    % The following \def is needed for color.sty since miniltx
    % (1996/11/21 version) does not do The Right Thing for \ExecuteOptions{}.
    \def\Gin@driver{pdftex.def}
    \input color.sty
\else
    % Assume dvips... xdvi is left out in the cold!
    % INCOMPLETE!  e.g., we need \rgbPagecolor, ...
    \def\Gin@driver{dvips.def}
    \input color.sty
\fi

\def\headfootcolour#1{%
    \def\headfootcolor{#1}
}


% The next two defs are taken from plain.tex of tetex-2.0.2, but
% modified as per pdfcolor.tex.

\def\makefootline{%
    \baselineskip24\p@
    \lineskiplimit\z@
    \line{{\color{\headfootcolor}\the\footline}}%
}

% This does not have the \mark things from pdfcolor.tex
\def\makeheadline{%
    \vbox to\z@{\vskip-22.5\p@
    \line{\vbox to8.5\p@{}{\color{\headfootcolor}\the\headline}}\vss}%
    \nointerlineskip
}

\headfootcolour{black}

\makeatother

% From pdfcolor.tex

\definecolor{greenYellow}{cmyk}{0.15,0,0.69,0}
\definecolor{goldenrod}{cmyk}{0,0.10,0.84,0}
\definecolor{dandelion}{cmyk}{0,0.29,0.84,0}
\definecolor{apricot}{cmyk}{0,0.32,0.52,0}
\definecolor{peach}{cmyk}{0,0.50,0.70,0}
\definecolor{melon}{cmyk}{0,0.46,0.50,0}
\definecolor{yellowOrange}{cmyk}{0,0.42,1,0}
\definecolor{orange}{cmyk}{0,0.61,0.87,0}
\definecolor{burntOrange}{cmyk}{0,0.51,1,0}
\definecolor{bittersweet}{cmyk}{0,0.75,1,0.24}
\definecolor{redOrange}{cmyk}{0,0.77,0.87,0}
\definecolor{mahogany}{cmyk}{0,0.85,0.87,0.35}
\definecolor{maroon}{cmyk}{0,0.87,0.68,0.32}
\definecolor{brickRed}{cmyk}{0,0.89,0.94,0.28}
\definecolor{orangeRed}{cmyk}{0,1,0.50,0}
\definecolor{rubineRed}{cmyk}{0,1,0.13,0}
\definecolor{wildStrawberry}{cmyk}{0,0.96,0.39,0}
\definecolor{salmon}{cmyk}{0,0.53,0.38,0}
\definecolor{carnationPink}{cmyk}{0,0.63,0,0}
\definecolor{violetRed}{cmyk}{0,0.81,0,0}
\definecolor{rhodamine}{cmyk}{0,0.82,0,0}
\definecolor{mulberry}{cmyk}{0.34,0.90,0,0.02}
\definecolor{redViolet}{cmyk}{0.07,0.90,0,0.34}
\definecolor{fuchsia}{cmyk}{0.47,0.91,0,0.08}
\definecolor{lavender}{cmyk}{0,0.48,0,0}
\definecolor{thistle}{cmyk}{0.12,0.59,0,0}
\definecolor{orchid}{cmyk}{0.32,0.64,0,0}
\definecolor{darkOrchid}{cmyk}{0.40,0.80,0.20,0}
\definecolor{purple}{cmyk}{0.45,0.86,0,0}
\definecolor{plum}{cmyk}{0.50,1,0,0}
\definecolor{violet}{cmyk}{0.79,0.88,0,0}
\definecolor{royalPurple}{cmyk}{0.75,0.90,0,0}
\definecolor{blueViolet}{cmyk}{0.86,0.91,0,0.04}
\definecolor{periwinkle}{cmyk}{0.57,0.55,0,0}
\definecolor{cadetBlue}{cmyk}{0.62,0.57,0.23,0}
\definecolor{cornflowerBlue}{cmyk}{0.65,0.13,0,0}
\definecolor{midnightBlue}{cmyk}{0.98,0.13,0,0.43}
\definecolor{navyBlue}{cmyk}{0.94,0.54,0,0}
\definecolor{royalBlue}{cmyk}{1,0.50,0,0}
\definecolor{cerulean}{cmyk}{0.94,0.11,0,0}
\definecolor{processBlue}{cmyk}{0.96,0,0,0}
\definecolor{skyBlue}{cmyk}{0.62,0,0.12,0}
\definecolor{turquoise}{cmyk}{0.85,0,0.20,0}
\definecolor{tealBlue}{cmyk}{0.86,0,0.34,0.02}
\definecolor{aquamarine}{cmyk}{0.82,0,0.30,0}
\definecolor{blueGreen}{cmyk}{0.85,0,0.33,0}
\definecolor{emerald}{cmyk}{1,0,0.50,0}
\definecolor{jungleGreen}{cmyk}{0.99,0,0.52,0}
\definecolor{seaGreen}{cmyk}{0.69,0,0.50,0}
\definecolor{green}{cmyk}{1,0,1,0}
\definecolor{forestGreen}{cmyk}{0.91,0,0.88,0.12}
\definecolor{pineGreen}{cmyk}{0.92,0,0.59,0.25}
\definecolor{limeGreen}{cmyk}{0.50,0,1,0}
\definecolor{yellowGreen}{cmyk}{0.44,0,0.74,0}
\definecolor{springGreen}{cmyk}{0.26,0,0.76,0}
\definecolor{oliveGreen}{cmyk}{0.64,0,0.95,0.40}
\definecolor{rawSienna}{cmyk}{0,0.72,1,0.45}
\definecolor{sepia}{cmyk}{0,0.83,1,0.70}
\definecolor{brown}{cmyk}{0,0.81,1,0.60}
\definecolor{tan}{cmyk}{0.14,0.42,0.56,0}
\definecolor{gray}{cmyk}{0,0,0,0.50}
