-
Notifications
You must be signed in to change notification settings - Fork 0
/
eushield.sty
54 lines (48 loc) · 1.46 KB
/
eushield.sty
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
50
51
52
53
54
%% eushield.sty -- commands to manipulate the inclusion of the EU shield
%% graphic.
%%
%% Version 1.0 [2000/11/23] -- initial version
%% Version 1.1 [2006/08/28] -- fixed PDF detection for teTeX 3
%%
%% Mary Ellen Foster <[email protected]>
\def\filedate{2006/08/28}
\def\fileversion{1.1}
\ProvidesPackage{eushield}[\filedate\ v\fileversion\
Commands for including the EU shield graphic]
\RequirePackage{graphics}
\RequirePackage{ifpdf}
%% Possible values for shieldtype:
%% 0: regular monochrome
%% 1: monochrome with no background lines
%% 2: reverse monochrome
%% 3: two colours: navy and red
%% 4: full colour
\newcommand{\eushield}{}
\newcommand{\@endspecial}{}
\newcommand{\shieldtype}[1]{%
\def\@shieldtype{#1}
\ifpdf
\ifnum\@shieldtype=0
\renewcommand{\eushield}{eushield-normal}
\else\ifnum\@shieldtype=1
\renewcommand{\eushield}{eushield-noback}
\else\ifnum\@shieldtype=2
\renewcommand{\eushield}{eushield-reversed}
\else\ifnum\@shieldtype=3
\renewcommand{\eushield}{eushield-twocolour}
\else\ifnum\@shieldtype=4
\renewcommand{\eushield}{eushield-fullcolour}
\fi\fi\fi\fi\fi
\else
\renewcommand{\eushield}{eushield}
\renewcommand{\@endspecial}{%
\special{!/crestversion #1 def}}
\fi
}
\shieldtype{0}
\newcommand{\includeshield}{%
\includegraphics{\eushield}}
\ifpdf
\else
\AtBeginDocument{\@endspecial}
\fi