summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/generic/ifxetex/ifxetex.sty
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/generic/ifxetex/ifxetex.sty')
-rw-r--r--Master/texmf-dist/tex/generic/ifxetex/ifxetex.sty38
1 files changed, 18 insertions, 20 deletions
diff --git a/Master/texmf-dist/tex/generic/ifxetex/ifxetex.sty b/Master/texmf-dist/tex/generic/ifxetex/ifxetex.sty
index b2d466ac3b4..d3707febc03 100644
--- a/Master/texmf-dist/tex/generic/ifxetex/ifxetex.sty
+++ b/Master/texmf-dist/tex/generic/ifxetex/ifxetex.sty
@@ -1,16 +1,11 @@
-%% LaTeX2e file `ifxetex.sty'
-%% generated by the `filecontents' environment
-%% from source `ifxetex' on 2008/09/18.
-%%
% \iffalse
-% Copyright 2006-2008 by Will Robertson <wspr81@gmail.com>
+% Copyright 2006-2009 by Will Robertson <wspr81@gmail.com>
%
% Distributable under the LaTeX Project Public License,
% version 1.3c or higher (your choice). The latest version of
% this license is at: http://www.latex-project.org/lppl.txt
%
-% This work is "maintained" (as per LPPL maintenance status)
-% by Will Robertson.
+% This work is maintained by Will Robertson.
% \fi
% Ensure loading a single time only
@@ -20,19 +15,7 @@
% Declare ourselves to \LaTeX
\expandafter\ifx\csname ProvidesPackage\endcsname\relax\else
\ProvidesPackage{ifxetex}
- [2008/09/18 v0.4 Provides ifxetex conditional]
-\fi
-
-% Create, if necessary, the \cmd\ifxetex\ conditional
-\expandafter\ifx\csname ifxetex\endcsname\relax
- \newif\ifxetex
-\fi
-
-% Set \cmd\ifxetex\ accordingly
-\expandafter\ifx\csname XeTeXrevision\endcsname\relax
- \xetexfalse
-\else
- \xetextrue
+ [2009/01/23 v0.5 Provides ifxetex conditional]
\fi
% For \XeTeX-exclusive packages
@@ -48,3 +31,18 @@
********************************************}%
\endgroup
\fi}
+
+% Abort if \cmd\ifxetex\ is already defined
+% (assume that it has already been set correctly)^^A
+% \footnote{Thanks to \textit{Dan Luecking} for suggesting this.}
+\expandafter\ifx\csname ifxetex\endcsname\relax\else
+ \expandafter\endinput
+\fi
+
+% Create and set \cmd\ifxetex\ accordingly
+\newif\ifxetex
+\expandafter\ifx\csname XeTeXrevision\endcsname\relax
+ \xetexfalse
+\else
+ \xetextrue
+\fi