summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2010-04-05 23:21:09 +0000
committerKarl Berry <karl@freefriends.org>2010-04-05 23:21:09 +0000
commit9b5e953d3b9474631ef0f47d624224e3840f14d8 (patch)
tree7a8b54e34c21cc892b8f3d6980fbfcccfc14ae2b
parentc7ab6260cbd5ecf7c748abf56df5d3a34ac8e70d (diff)
new generic package iftex (5apr10)
git-svn-id: svn://tug.org/texlive/trunk@17720 c570f23f-e606-0410-a88d-b1316a301751
-rw-r--r--Master/texmf-dist/doc/generic/iftex/README20
-rw-r--r--Master/texmf-dist/doc/generic/iftex/iftex.pdfbin0 -> 143101 bytes
-rw-r--r--Master/texmf-dist/doc/generic/iftex/iftex.tex80
-rw-r--r--Master/texmf-dist/tex/generic/iftex/iftex.sty94
-rwxr-xr-xMaster/tlpkg/bin/tlpkg-ctan-check4
-rwxr-xr-xMaster/tlpkg/libexec/ctan2tds2
-rw-r--r--Master/tlpkg/tlpsrc/collection-genericextra.tlpsrc1
-rw-r--r--Master/tlpkg/tlpsrc/iftex.tlpsrc0
8 files changed, 200 insertions, 1 deletions
diff --git a/Master/texmf-dist/doc/generic/iftex/README b/Master/texmf-dist/doc/generic/iftex/README
new file mode 100644
index 00000000000..124c99c6157
--- /dev/null
+++ b/Master/texmf-dist/doc/generic/iftex/README
@@ -0,0 +1,20 @@
+_________________
+The iftex package
+v0.1
+
+This very simple package, for both Plain TeX and LaTeX,
+defines the \ifPDFTeX, \ifXeTeX, and \ifLuaTeX boolean
+for testing whether PDFTeX, or XeTeX, or LuaTeX is being
+used for typesetting.
+
+Also provides the \RequirePDFTeX, \RequireXeTeX, and \RequireLuaTeX
+command which throws an error if PDFTeX, XeTeX and LuaTeX (respectively)
+is not the engine in use.
+
+
+______________
+Vafa Khalighi
+vafakh84@gmail.com
+
+Copyright 2010
+Distributed under the LaTeX Project Public License
diff --git a/Master/texmf-dist/doc/generic/iftex/iftex.pdf b/Master/texmf-dist/doc/generic/iftex/iftex.pdf
new file mode 100644
index 00000000000..261aa8181c1
--- /dev/null
+++ b/Master/texmf-dist/doc/generic/iftex/iftex.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/generic/iftex/iftex.tex b/Master/texmf-dist/doc/generic/iftex/iftex.tex
new file mode 100644
index 00000000000..7914276f004
--- /dev/null
+++ b/Master/texmf-dist/doc/generic/iftex/iftex.tex
@@ -0,0 +1,80 @@
+\documentclass{artikel3}
+\usepackage{calc}
+\usepackage{pifont}
+\usepackage{bbding}
+\usepackage[colorlinks=true,linkcolor=mybrown,urlcolor=mygreen]{hyperref}
+\usepackage{bidicode}
+\newcounter{local}
+\renewcommand\theenumi{\protect\setcounter{local}%
+ {201+\the\value{enumi}}\protect\ding{\value{local}}}
+\renewcommand\labelenumi{\theenumi}
+\renewcommand\labelitemi{\HandRight}
+\renewcommand\labelitemii{\HandRightUp}
+\renewcommand\labelitemiii{\HandCuffRight}
+\renewcommand\labelitemiv{\HandPencilLeft}
+\definecolor{mybrown}{rgb}{.6,0,0}
+\definecolor{mygreen}{rgb}{0,.43,0}
+\definecolor{Orange}{rgb}{1,.4,.2}
+\newcommand\PDFTeX{PDF\TeX}
+\newcommand\XeTeX{Xe\TeX}
+\newcommand\LuaTeX{Lua\TeX}
+\title{The \textsf{iftex} Package\\ \href{http://bitbucket.org/vafa/iftex}{\texttt{http://bitbucket.org/vafa/iftex}}}
+\author{Vafa Khalighi\\ \href{mailto:vafakh84@gmail.com}{\texttt{vafakh84@gmail.com}}}
+\date{Version 0.1}
+\begin{document}
+\maketitle
+\tableofcontents
+\section{Introduction}
+This package provides a way to check if a document is being processed with \PDFTeX, or \XeTeX, or \LuaTeX.
+\section{Loading The Package}
+The package can be loaded in the usual way both in Plain \TeX\ and \LaTeX.
+\subsection{Loading The Package in Plain \TeX}
+\begin{BDef}
+\Lcs{input}\quad \Larg{iftex.sty}
+\end{BDef}
+\subsection{Loading The Package in \LaTeX}
+\begin{BDef}
+\Lcs{usepackage}\Largb{iftex}
+\end{BDef}
+\section{Defined Conditionals}
+\subsection{For \PDFTeX}
+\begin{BDef}
+\Lcs{ifPDFTeX}\\
+\qquad\Larga{material for \PDFTeX}\\
+\Lcs{else}\\
+\qquad\Larga{material not for \PDFTeX}\\
+\Lcs{fi}
+\end{BDef}
+\subsection{For \XeTeX}
+\begin{BDef}
+\Lcs{ifXeTeX}\\
+\qquad\Larga{material for \XeTeX}\\
+\Lcs{else}\\
+\qquad\Larga{material not for \XeTeX}\\
+\Lcs{fi}
+\end{BDef}
+\subsection{For \LuaTeX}
+\begin{BDef}
+\Lcs{ifLuaTeX}\\
+\qquad\Larga{material for \LuaTeX}\\
+\Lcs{else}\\
+\qquad\Larga{material not for \LuaTeX}\\
+\Lcs{fi}
+\end{BDef}
+\section{Defined Commands}
+\subsection{For \PDFTeX}
+\begin{BDef}
+\Lcs{RequirePDFTeX}
+\end{BDef}
+This command tests for \PDFTeX\ use and throws an error if a different engine is being used.
+\subsection{For \XeTeX}
+\begin{BDef}
+\Lcs{RequireXeTeX}
+\end{BDef}
+This command tests for \XeTeX\ use and throws an error if a different engine is being used.
+\subsection{For \LuaTeX}
+\begin{BDef}
+\Lcs{RequireLuaTeX}
+\end{BDef}
+This command tests for \LuaTeX\ use and throws an error if a different engine is being used.
+\end{document} \ No newline at end of file
diff --git a/Master/texmf-dist/tex/generic/iftex/iftex.sty b/Master/texmf-dist/tex/generic/iftex/iftex.sty
new file mode 100644
index 00000000000..4a6407df6a2
--- /dev/null
+++ b/Master/texmf-dist/tex/generic/iftex/iftex.sty
@@ -0,0 +1,94 @@
+%%
+%% This is file `iftex.sty',
+
+%%
+%% __________________________________
+%% Copyright © 2010 Vafa Khalighi
+%%
+%% License information appended.
+%%
+%%
+\csname iftexloaded\endcsname
+\let\iftexloaded\endinput
+\expandafter\ifx\csname ProvidesPackage\endcsname\relax\else
+ \ProvidesPackage{iftex}
+ [2010/07/25 v0.1 Provides if(tex) conditional for PDFTeX, XeTeX, and LuaTeX]
+\fi
+\def\RequirePDFTeX{%
+ \ifPDFTeX\else
+ \begingroup
+ \errorcontextlines=-1\relax
+ \newlinechar=10\relax
+ \errmessage{^^J
+ ********************************************^^J
+ * PDFTeX is required to compile this document.^^J
+ * Sorry!^^J
+ ********************************************}%
+ \endgroup
+ \fi}
+\def\RequireXeTeX{%
+ \ifXeTeX\else
+ \begingroup
+ \errorcontextlines=-1\relax
+ \newlinechar=10\relax
+ \errmessage{^^J
+ ********************************************^^J
+ * XeTeX is required to compile this document.^^J
+ * Sorry!^^J
+ ********************************************}%
+ \endgroup
+ \fi}
+\def\RequireLuaTeX{%
+ \ifLuaTeX\else
+ \begingroup
+ \errorcontextlines=-1\relax
+ \newlinechar=10\relax
+ \errmessage{^^J
+ ********************************************^^J
+ * LuaTeX is required to compile this document.^^J
+ * Sorry!^^J
+ ********************************************}%
+ \endgroup
+ \fi}
+\expandafter\ifx\csname ifPDFTeX\endcsname\relax\else
+ \expandafter\endinput
+\fi
+\expandafter\ifx\csname ifXeTeX\endcsname\relax\else
+ \expandafter\endinput
+\fi
+\expandafter\ifx\csname ifLuaTeX\endcsname\relax\else
+ \expandafter\endinput
+\fi
+\newif\ifPDFTeX
+\expandafter\ifx\csname pdfmatch\endcsname\relax
+ \PDFTeXfalse
+\else
+ \PDFTeXtrue
+\fi
+\newif\ifXeTeX
+\expandafter\ifx\csname XeTeXinterchartoks\endcsname\relax
+ \XeTeXfalse
+\else
+ \XeTeXtrue
+\fi
+\newif\ifLuaTeX
+\expandafter\ifx\csname directlua\endcsname\relax
+ \LuaTeXfalse
+\else
+ \LuaTeXtrue
+\fi
+%%
+%% Copyright © 2010 by Vafa Khalighi <vafakh84@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 Vafa Khalighi.
+%%
+%%
+%%
+%%
+%%
+%% End of file `iftex.sty'.
diff --git a/Master/tlpkg/bin/tlpkg-ctan-check b/Master/tlpkg/bin/tlpkg-ctan-check
index a5692c219fd..5e0092a475a 100755
--- a/Master/tlpkg/bin/tlpkg-ctan-check
+++ b/Master/tlpkg/bin/tlpkg-ctan-check
@@ -21,6 +21,7 @@ our %OPT;
# these packages should be up to date:
my @TLP_working = qw(
12many
+ IEEEconf IEEEtran
a0poster a2ping a4wide a5comb
aastex abbr abc abstract abstyles accfonts achemso
acmconf acmtrans acromake acronym
@@ -150,7 +151,8 @@ my @TLP_working = qw(
hhtensor histogr historische-zeitschrift hitec hrlatex hvfloat hvindex
hypdvips hyper hypernat hyperref hyperxmp hyph-utf8 hyphen-base
hyphenat hyphenex hyplain
- ibygrk icsv idxlayout IEEEconf ieeepes IEEEtran ifmtarg ifplatform ifxetex
+ ibygrk icsv idxlayout ieeepes
+ ifmtarg ifplatform iftex ifxetex
ijmart ijqc imac image-gallery impatient impatient-fr import imtekda
inconsolata inlinebib inlinedef insbox
interactiveworkbook intro-scientific inversepath
diff --git a/Master/tlpkg/libexec/ctan2tds b/Master/tlpkg/libexec/ctan2tds
index 3a1032294d6..33a63561a56 100755
--- a/Master/tlpkg/libexec/ctan2tds
+++ b/Master/tlpkg/libexec/ctan2tds
@@ -751,6 +751,7 @@ $standarddest = "texmf-dist";
'hyphenex', 'generic',
'hyplain', 'plain',
'ibygrk', 'generic',
+ 'iftex', 'generic',
'ifxetex', 'generic',
'jadetex', 'jadetex',
'mathabx', 'generic',
@@ -1076,6 +1077,7 @@ $standardtex='\.(.bx|cfg|sty|clo|ldf|cls|def|fd|cmap|4ht)$';
'hieroglf', 'fonts',
'hyplain', 'plain',
'ibygrk', 'fonts',
+ 'iftex', 'generic',
'ifxetex', 'generic',
'ijqc', 'bibtex',
'impatient-fr', 'plain',
diff --git a/Master/tlpkg/tlpsrc/collection-genericextra.tlpsrc b/Master/tlpkg/tlpsrc/collection-genericextra.tlpsrc
index d73e4d6e8ed..bc3591c8cb6 100644
--- a/Master/tlpkg/tlpsrc/collection-genericextra.tlpsrc
+++ b/Master/tlpkg/tlpsrc/collection-genericextra.tlpsrc
@@ -14,6 +14,7 @@ depend eijkhout
depend encxvlna
depend fenixpar
depend fltpoint
+depend iftex
depend insbox
depend librarian
depend mathdots
diff --git a/Master/tlpkg/tlpsrc/iftex.tlpsrc b/Master/tlpkg/tlpsrc/iftex.tlpsrc
new file mode 100644
index 00000000000..e69de29bb2d
--- /dev/null
+++ b/Master/tlpkg/tlpsrc/iftex.tlpsrc