% \iffalse %<*driver> \documentclass{ltxdoc} \begin{document} \DocInput{europs.dtx} \end{document} % % \fi % % \changes{v1.2}{1999/01/16}{added \\EURofc, updated documentation} % \changes{v1.1}{1998/11/02}{switched to docstrip, added subsituition rules} % \changes{v1.0}{1998/10/29}{initial version, not using docstrip} % % \title{\textsf{europs} -- Using Adobe's Euro Currency Symbol Fonts % with \LaTeXe} % \author{J\"orn Clausen\footnote{\texttt{joern@TechFak.Uni-Bielefeld.DE}}} % \maketitle % % \section{The Style File} % First we introduce ourself and request a reasonable \LaTeX{} version. % \begin{macrocode} %<*style> \ProvidesPackage{europs} [1999/01/16 v1.2 Euro Currency Symbol PostScript] \NeedsTeXFormat{LaTeX2e} % \end{macrocode} % % I prefer the \textsf{ifthen} package over using plain\TeX{} commands. This % is said to be more portable, anyway\dots % \begin{macrocode} \RequirePackage{ifthen} % \end{macrocode} % % Now we define three macros to access the three font families. The actual % glyph each macro produces still depends on the current selection of series % and shape. If the macro |\EURtm| is used inside e.g. |\textbf{}|, the % macro takes the symbol from EuroSerif Bold. % \begin{macro}{\EURtm} % |\EURtm| selects the Euro symbol from the EuroSerif family. The name % should indicate that this shape can be combined with fonts like Times. % \begin{macrocode} \providecommand{\EURtm}{{\fontencoding{U}\fontfamily{zpeu}\selectfont E}} % \end{macrocode} % \end{macro} % \begin{macro}{\EURhv} % |\EURhv| prints the sans serif version of the Euro symbol. The association % is that this symbol looks like Helvetica. % \begin{macrocode} \providecommand{\EURhv}{{\fontencoding{U}\fontfamily{zpeus}\selectfont E}} % \end{macrocode} % \end{macro} % \begin{macro}{\EURcr} % |\EURcr| finally is a monospaced version of the Euro symbol. It can be % combined with Courier and similar typewriter fonts. % \begin{macrocode} \providecommand{\EURcr}{{\fontencoding{U}\fontfamily{zpeut}\selectfont E}} % \end{macrocode} % \end{macro} % \begin{macro}{\EUR} % This macro selects one of the three symbols defined above, depending on % the current font family. This way, \verb|\EUR| follows all the usual font % changes one can perform with the \verb|\text..{}| commands. % \begin{macrocode} \providecommand{\EUR}{% \ifthenelse{\equal{\f@family}{\rmdefault}}% {\EURtm}% {\ifthenelse{\equal{\f@family}{\ttdefault}}% {\EURcr}% {\EURhv}}% } % \end{macrocode} % \end{macro} % \begin{macro}{\EURofc} % Having defined all these different symbols, the truth is, that there % \emph{should} be only one symbol. It is the one represented by % EuroSans Regular. So if you want to conform with the rules of the European % bureaucrats, and break the rules of typesetters and designers, you can use % |\EURofc| to get the ``official'' Euro symbol, independent of the current % context. % \begin{macrocode} \providecommand{\EURofc}{{\usefont{U}{zpeus}{m}{n} E}} % \end{macrocode} % \end{macro} % \begin{macrocode} % % \end{macrocode} % % \section{The Font Definitions} % Now we have to provide font definitions to introduce the three families % to NFSS. % \subsection{EuroSerif} % First, the definitions for EuroSerif: % \begin{macrocode} %<*uzpeu> \ProvidesFile{uzpeu.fd} [1999/01/16 v1.2 font definitions for U/zpeu] \DeclareFontFamily{U}{zpeu}{} \DeclareFontShape{U}{zpeu}{m}{n}{<->zpeur}{} \DeclareFontShape{U}{zpeu}{m}{it}{<->zpeuri}{} \DeclareFontShape{U}{zpeu}{bx}{n}{<->zpeub}{} \DeclareFontShape{U}{zpeu}{bx}{it}{<->zpeubi}{} % \end{macrocode} % We define some substitution rules that might be useful. % \begin{macrocode} \DeclareFontShape{U}{zpeu}{b}{n}{<->ssub * zpeu/bx/n}{} \DeclareFontShape{U}{zpeu}{b}{it}{<->ssub * zpeu/bx/it}{} \DeclareFontShape{U}{zpeu}{m}{sl}{<->ssub * zpeu/m/it}{} \DeclareFontShape{U}{zpeu}{bx}{sl}{<->ssub * zpeu/bx/it}{} % % \end{macrocode} % % \subsection{EuroSans} % The definitions for EuroSans are essentially the same: % \begin{macrocode} %<*uzpeus> \ProvidesFile{uzpeus.fd} [1999/01/16 v1.2 font definitions for U/zpeus] \DeclareFontFamily{U}{zpeus}{} \DeclareFontShape{U}{zpeus}{m}{n}{<->zpeurs}{} \DeclareFontShape{U}{zpeus}{m}{it}{<->zpeuris}{} \DeclareFontShape{U}{zpeus}{bx}{n}{<->zpeubs}{} \DeclareFontShape{U}{zpeus}{bx}{it}{<->zpeubis}{} \DeclareFontShape{U}{zpeus}{b}{n}{<->ssub * zpeus/bx/n}{} \DeclareFontShape{U}{zpeus}{b}{it}{<->ssub * zpeus/bx/it}{} \DeclareFontShape{U}{zpeus}{m}{sl}{<->ssub * zpeus/m/it}{} \DeclareFontShape{U}{zpeus}{bx}{sl}{<->ssub * zpeus/bx/it}{} % % \end{macrocode} % \subsection{EuroMono} % And finally the definitions for EuroMono: % \begin{macrocode} %<*uzpeut> \ProvidesFile{uzpeut.fd} [1999/01/16 v1.2 font definitions for U/zpeut] \DeclareFontFamily{U}{zpeut}{} \DeclareFontShape{U}{zpeut}{m}{n}{<->zpeurt}{} \DeclareFontShape{U}{zpeut}{m}{it}{<->zpeurit}{} \DeclareFontShape{U}{zpeut}{bx}{n}{<->zpeubt}{} \DeclareFontShape{U}{zpeut}{bx}{it}{<->zpeubit}{} \DeclareFontShape{U}{zpeut}{b}{n}{<->ssub * zpeut/bx/n}{} \DeclareFontShape{U}{zpeut}{b}{it}{<->ssub * zpeut/bx/it}{} \DeclareFontShape{U}{zpeut}{m}{sl}{<->ssub * zpeut/m/it}{} \DeclareFontShape{U}{zpeut}{bx}{sl}{<->ssub * zpeut/bx/it}{} %<*zpeut> % \end{macrocode}