%% %% This is file `eemeir.sty', %% generated with the docstrip utility. %% %% The original source files were: %% %% eemeir.dtx (with options: `package') %% %% m This is the E-Em-Eir package %% o Copyright 2003-07 by Mogens Lemvig Hansen, %% g Please find my e-mail address in the left margin %% e %% n Run eemeir.dtx through LaTeX and read the documentation in eemeir.dvi %% s %% @ This work may be distributed and/or modified under the %% k conditions of the LaTeX Project Public License, either version 1.3 %% a of this license or (at your option) any later version. %% y The latest version of this license is in %% j http://www.latex-project.org/lppl.txt %% u and version 1.3 or later is part of all distributions of LaTeX %% . version 2003/12/01 or later. %% c %% o This work has the LPPL maintenance status 'maintained'. %% m %% The Current Maintainer of this work is Mogens Lemvig Hansen. %% %% This work consists of the files eemeir.dtx and eemeir.ins %% and the derived file eemeir.sty. %% \NeedsTeXFormat{LaTeX2e} \ProvidesPackage{eemeir}[2007/02/19 v1.1 E-Em-Eir package] \newcommand{\@eemeir}{\relax} \newcommand{\@eemeirM}{\relax} \newcommand{\@eemeirF}{\relax} \DeclareOption{male} {\def\@eemeir{\male[]}} \DeclareOption{female}{\def\@eemeir{\female[]}} \DeclareOption{ask} {\def\@eemeir{\askforgender[]}} \ExecuteOptions{ask} \ProcessOptions \RequirePackage{xspace} \newcommand{\male}[1][]{% \@bsphack \@ifundefined{ifmale#1} {\expandafter\newif\csname ifmale#1\endcsname} {\relax}% \csname male#1true\endcsname \@esphack} \newcommand{\female}[1][]{% \@bsphack \@ifundefined{ifmale#1} {\expandafter\newif\csname ifmale#1\endcsname} {\relax}% \csname male#1false\endcsname \@esphack} \newcommand{\askforgender}[1][]{% \@bsphack \@ifundefined{ifmale#1} {\expandafter\newif\csname ifmale#1\endcsname} {\relax}% \def\@eemeir{#1}% \ifx\@eemeir\@empty\def\@eemeir{main}\fi \typein[\@eemeir]{Specify the \@eemeir\space gender:% \space\space male\space\space or\space\space female}% \def\@eemeirM{male}% \def\@eemeirF{female}% \ifx\@eemeir\@eemeirM\male[#1]% \else\ifx\@eemeir\@eemeirF\female[#1]% \else\PackageError{eemeir} {I'll ignore that} {You should have typed either\space\space male\space\space or\space\space female}% \fi\fi \@esphack } \newenvironment{swapgender}[1][]{% \@bsphack \@ifundefined{ifmale#1} {\PackageError{eemeir}{unknown gender: #1} {You must set the #1 gender with \string\male\space (or...) first.}} {\csname ifmale#1\endcsname\csname male#1false\endcsname \else\csname male#1true\endcsname\fi}% \@esphack} {\@bsphack\@Esphack} \newcommand{\newwordpair} {\@newwordpair\newcommand} \newcommand{\renewwordpair}{\@newwordpair\renewcommand} \newcommand{\@newwordpair}[4]{% #1{#2}{\@ifstar {\def\@eemeirM{\MakeUppercase#3}% \def\@eemeirF{\MakeUppercase#4}% \@eemeirword} {\def\@eemeirM{#3}% \def\@eemeirF{#4}% \@eemeirword}}% } \newcommand{\@eemeirword}[1][]{% \@ifundefined{ifmale#1} {\PackageWarning{eemeir} {You should set the #1 gender before using\MessageBreak it}% \askforgender[#1]} {\relax}% \csname ifmale#1\endcsname\@eemeirM\else\@eemeirF\fi \xspace } \newwordpair{\E}{he}{she} \newwordpair{\Em}{him}{her} \newwordpair{\Eir}{his}{her} \newwordpair{\Eirs}{his}{hers} \@eemeir \endinput %% %% End of file `eemeir.sty'.