summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2010-04-03 23:10:43 +0000
committerKarl Berry <karl@freefriends.org>2010-04-03 23:10:43 +0000
commitf4f2bda7875b29f071a079559aa724434922d1ec (patch)
tree6eb02f162ce806ee2ac6dcad23e58e7f55018644 /Master/texmf-dist/tex/latex
parentce612f56f26d1e7d403ac8cd02d8b4ce9642e93f (diff)
xypdf update (31mar10)
git-svn-id: svn://tug.org/texlive/trunk@17673 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex')
-rw-r--r--Master/texmf-dist/tex/latex/xypdf/xypdf.sty170
1 files changed, 142 insertions, 28 deletions
diff --git a/Master/texmf-dist/tex/latex/xypdf/xypdf.sty b/Master/texmf-dist/tex/latex/xypdf/xypdf.sty
index f12cea76b0d..904dc3cc8c5 100644
--- a/Master/texmf-dist/tex/latex/xypdf/xypdf.sty
+++ b/Master/texmf-dist/tex/latex/xypdf/xypdf.sty
@@ -28,22 +28,23 @@
%% This file is part of the LaTeX2e xypdf package. The package
%% consists of the following files:
%%
-%% README - The distribution guide
-%% xypdf.dtx - Documented source code
-%% xypdf.ins - Installation script
-%% xypdf.sty - LaTeX style file
-%% xypdf.pdf - Documentation
+%% README - This file, the distribution guide
+%% xypdf.dtx - Documented source code
+%% xypdf.ins - Installation script
+%% xypdf.pdf - Documentation (generated from xypdf.dtx)
+%%
+%% The LaTeX style file xypdf.sty is generated by the following command:
+%%
+%% latex xypdf.ins
%%
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{xypdf}
- [2010/03/24 v1.0 PDF output for the Xy-pic package]
+ [2010/03/30 v1.1 PDF output for the Xy-pic package]
\@ifpackageloaded{xy}\relax
{\PackageError{xypdf}{Load the Xy-pic package before this package}
{Insert `\string\usepackage[<options>]{xy}' before
`\string\usepackage{xypdf}'}}
-\ifdefined\xypsloaded
-\PackageError{xypdf}{Do not load Xy-pic with a Postscript backend}{}
-\fi
+\xywithoption{ps}{\PackageError{xypdf}{Do not load Xy-pic with a Postscript backend}{}}
\RequirePackage{ifpdf}
\newcommand*\xypdfon{}
\newcommand*\xypdfoff{}
@@ -54,14 +55,24 @@
}\edef\xypdfoff{\unexpanded\expandafter{\xypdfoff}\let\expandafter\noexpand\csname#1\endcsname
\expandafter\noexpand\csname xP@old@#1\endcsname
}}
-\AtEndOfPackage{\xypdfon\let\xP@hook\@undefined\let\xP@tempvar\@undefined}
+\AtEndOfPackage{\xypdfon
+\let\xP@hook\@undefined
+\let\xP@tempvar\@undefined
+\let\@tempa\@undefined
+\let\xP@gobblepart\@undefined
+\let\xP@endgobble\@undefined
+}
\@ifdefinable\xP@literal\relax
\ifpdf
\let\xP@literal\pdfliteral
\else
-\def\xP@literal#1{\special{pdf:literal #1}}
+\def\xP@literal{\PackageWarning{xypdf}{The produced DVI file is NOT PORTABLE. Convert it with^^Jdvipdfm(x) to the PDF format but do not expect the DVI itself to be displayed^^Jcorrectly\@gobble}\global\let\xP@literal\xP@literal@
+\xP@literal
+}
+\newcommand*\xP@literal@[1]{\special{pdf:literal #1}}
\fi
-\newcommand*\xP@dim[1]{\expandafter\removePT@\the\dimexpr(#1)*800/803\relax\space}
+\newcommand*\xP@dim[1]{\xP@EARPT\dimexpr(#1)*800/803\relax\space}
+\newcommand*\xP@EARPT{\expandafter\removePT@\the}
\newcommand*\xP@coor[1]{\xP@dim{#1}\xP@dim}
\AtBeginDocument{{\setbox0\hbox{$ $}}\@ifdefinable\xP@lw\relax
\edef\xP@lw{\xP@dim{\fontdimen8\textfont3}}\PackageInfo{xypdf}{Line width: \the\fontdimen8\textfont3 }}
@@ -196,6 +207,124 @@
}}
\newcommand*\xP@append[2]{{\edef\@tempa{#1{\the#1#2}}\expandafter}\@tempa
}
+\xP@hook{circhar@@}
+\newcommand*\xP@circhar@@[1]{\expandafter\xP@circhar@@@\ifcase#1 000{-173517671/654249180}{65307479/619869377}{-34221476/65864945}{225058681/768398401}{-543339720/768398401}\or
+0{-543339720/768398401}{181455824/967576667}{-554561898/619869377}{826676217/1870772527}{-1}{543339720/768398401}{-1}\or
+0{-1}{173517671/654249180}{-1}{34221476/65864945}{-554561898/619869377}{543339720/768398401}{-543339720/768398401}\or
+0{-543339720/768398401}{181455824/967576667}{-34221476/65864945}{225058681/768398401}{-173517671/654249180}{225058681/768398401}0\or
+0{543339720/768398401}{181455824/967576667}{34221476/65864945}{225058681/768398401}{173517671/654249180}{225058681/768398401}0\or
+01{173517671/654249180}1{34221476/65864945}{554561898/619869377}{543339720/768398401}{543339720/768398401}\or
+0{543339720/768398401}{181455824/967576667}{554561898/619869377}{826676217/1870772527}1{543339720/768398401}1\or
+000{173517671/654249180}{65307479/619869377}{34221476/65864945}{225058681/768398401}{543339720/768398401}\fi}
+\newcommand\xP@circhar@@@[8]{\xP@setsolidpat
+\xP@stroke{\xP@coor{\R@*#1}{\R@*#2}m
+\xP@coor{\R@*#3}{\R@*#4}\xP@coor{\R@*#5}{\R@*#6}\xP@coor{\R@*#7}{\R@*#8}c}\vrule width\z@ height\R@ depth\R@
+\kern\dimexpr\R@*#7\relax
+}
+\xP@hook{cirrestrict@@}
+\newcommand*\xP@cirrestrict@@{\count@\z@\relax}
+\newcommand*\xP@optionalsection[1]{\expandafter\ifx\csname xy#1loaded\endcsname\relax
+\xywithoption{#1}{\xP@optionerror{#1}}\expandafter\xP@gobblepart
+\else
+\message{`#1' extension support,}\fi
+}
+\newcommand*\xP@optionerror[1]{\PackageError{xypdf}{Load the Xy-pic "#1" option before the xypdf package}{}}
+\@ifdefinable\xP@gobblepart\relax
+\long\def\xP@gobblepart#1\xP@endgobble{}
+\newcommand*\xP@endgobble{\relax}
+\xP@optionalsection{rotate}
+\newcommand*\xP@scale[2]{\setboxz@h{\hskip\L@p
+\hskip-\R@p
+\lower\U@p\hbox{\xP@literal{q #1\space0 0 #2\space0 0 cm}\raise\U@p\hb@xt@\z@{\hskip-\L@p\boxz@\hss}\xP@literal{Q}}}}
+\newcommand\xP@rotate{\xP@rotate@\xP@trigfromdir
+}
+\@ifdefinable\xP@specialrotate\relax
+\def\xP@specialrotate#1@@{\xP@rotate@\xP@trig{#1\p@}}
+\newcommand*\xP@rotate@[2]{\setboxz@h{#1{#2}\hskip\L@p
+\hskip-\R@p
+\lower\U@p\hbox{\xP@literal{q \cosDirection\space
+\sinDirection\space
+\if-\sinDirection\else-\sinDirection\fi\space
+\cosDirection\space
+0 0 cm}\raise\U@p\hb@xt@\z@{\hskip-\L@p\boxz@\hss}\xP@literal{Q}}}}
+\CheckCommand*\xyRotate@@[1]{\xyundefinedRotate@{rotate}{#1}@@}
+\let\xyRotate@@\xP@rotate
+\def\@tempa#1@@{\xyundefinedRotate@{special rotate}{#1}@@}
+\@check@eq\doSpecialRotate@@\@tempa
+\let\doSpecialRotate@@\xP@specialrotate
+\CheckCommand*\xyscale@[2]{\xyundefinedRotate@{scale}{#1,#2}@@}
+\let\xyscale@@\xP@scale
+\newcommand*\xP@trigfromdir[1]{{\Direction#1\relax
+\count@-\Direction
+\advance\count@4096
+\divide\count@2048
+\ifcase\count@
+\d@X\K@\p@
+\d@Y\numexpr\Direction-3*\K@\relax\p@
+\or
+\d@X\numexpr\Direction-\K@\relax\p@
+\d@Y-\K@\p@
+\or
+\d@X-\K@\p@
+\d@Y\numexpr-\Direction-\K@\relax\p@
+\or
+\d@X\numexpr-\Direction-3*\K@\relax\p@
+\d@Y\K@\p@
+\else
+\PackageError{xypdf}{Unexpected case in direction calculation}{Feel free to contact the author of the xypdf package with a minimal example.}\fi
+\xP@veclen
+\xdef\@gtempa{\def\noexpand\cosDirection{\xP@EARPT\dimexpr\d@X*\p@/\@tempdimb\relax}\def\noexpand\sinDirection{\xP@EARPT\dimexpr\d@Y*\p@/\@tempdimb\relax}}}\@gtempa
+}
+\newcommand*\xP@trig[1]{\@tempdima\dimexpr#1\relax
+\@tempdimb\@tempdima
+\divide\@tempdimb23592960
+\advance\@tempdima-23592960\@tempdimb
+\ifdim\@tempdima<\z@\advance\@tempdima360pt\fi
+\@tempdimb\@tempdima
+\divide\@tempdimb5898240
+\ifcase\@tempdimb
+\xP@sinpoly
+\edef\sinDirection{\xP@EARPT\@tempdimb}\@tempdima\dimexpr90pt-\@tempdima\relax
+\xP@sinpoly
+\edef\cosDirection{\xP@EARPT\@tempdimb}\or
+\@tempdima\dimexpr180pt-\@tempdima\relax
+\xP@sinpoly
+\edef\sinDirection{\xP@EARPT\@tempdimb}\@tempdima\dimexpr90pt-\@tempdima\relax
+\xP@sinpoly
+\edef\cosDirection{\xP@EARPT\dimexpr-\@tempdimb\relax}\or
+\@tempdima\dimexpr\@tempdima-180pt\relax
+\xP@sinpoly
+\edef\sinDirection{\xP@EARPT\dimexpr-\@tempdimb\relax}\@tempdima\dimexpr90pt-\@tempdima\relax
+\xP@sinpoly
+\edef\cosDirection{\xP@EARPT\dimexpr-\@tempdimb\relax}\or
+\@tempdima\dimexpr360pt-\@tempdima\relax
+\xP@sinpoly
+\edef\sinDirection{\xP@EARPT\dimexpr-\@tempdimb\relax}\@tempdima\dimexpr90pt-\@tempdima\relax
+\xP@sinpoly
+\edef\cosDirection{\xP@EARPT\@tempdimb}\else
+\PackageError{xypdf}{Unexpected case in sin/cos calculation}{Feel free to contact the author of the xypdf package with a minimal example.}\fi
+}
+\newcommand*\xP@sinpoly{{\ifdim\@tempdima<49pt
+\ifdim\@tempdima<27pt
+\@tempdimb\dimexpr((\@tempdima*-529771058/16039085-1384933sp)*\@tempdima/268756075+10714164sp)*\@tempdima/613777813\relax
+\else
+\advance\@tempdima-27pt
+\@tempdimb\dimexpr(((\@tempdima*-743101305/20672414-238989613sp)*\@tempdima/80975565+42661556sp)*\@tempdima/622461739+2\p@)*157520747/693945047\relax
+\fi
+\else
+\ifdim\@tempdima<70pt
+\advance\@tempdima-49pt
+\@tempdimb\dimexpr(((\@tempdima*-348406699/107952940-55079229sp)*\@tempdima/866635628+408805sp)*\@tempdima/26926757+\p@)*135751711/179873976\relax
+\else
+\advance\@tempdima-70pt
+\@tempdimb\dimexpr(((\@tempdima*-1015850353/137849442-460519207sp)*\@tempdima/8742349+142263941sp)*\@tempdima/972432199+23\p@)*31253604/764969669\relax
+\fi
+\fi
+\global\dimen@i\@tempdimb
+}\@tempdimb\dimen@i
+}
+\xP@endgobble
+\xP@optionalsection{curve}
\newcommand*\xP@tempvar[2]{\@ifdefinable#1\relax
\let#1#2}
\xP@tempvar\xP@bigdim\quotPTK@
@@ -1229,22 +1358,7 @@
{\xP@posX+\X@max}{\xP@posY-\Y@max}\or
{\xP@posX+\D@p+\X@min}{\xP@posY-\R@p+\Y@min}\fi
}}
-\xP@hook{circhar@@}
-\newcommand*\xP@circhar@@[1]{\expandafter\xP@circhar@@@\ifcase#1 000{-173517671/654249180}{65307479/619869377}{-34221476/65864945}{225058681/768398401}{-543339720/768398401}\or
-0{-543339720/768398401}{181455824/967576667}{-554561898/619869377}{826676217/1870772527}{-1}{543339720/768398401}{-1}\or
-0{-1}{173517671/654249180}{-1}{34221476/65864945}{-554561898/619869377}{543339720/768398401}{-543339720/768398401}\or
-0{-543339720/768398401}{181455824/967576667}{-34221476/65864945}{225058681/768398401}{-173517671/654249180}{225058681/768398401}0\or
-0{543339720/768398401}{181455824/967576667}{34221476/65864945}{225058681/768398401}{173517671/654249180}{225058681/768398401}0\or
-01{173517671/654249180}1{34221476/65864945}{554561898/619869377}{543339720/768398401}{543339720/768398401}\or
-0{543339720/768398401}{181455824/967576667}{554561898/619869377}{826676217/1870772527}1{543339720/768398401}1\or
-000{173517671/654249180}{65307479/619869377}{34221476/65864945}{225058681/768398401}{543339720/768398401}\fi}
-\newcommand\xP@circhar@@@[8]{\xP@setsolidpat
-\xP@stroke{\xP@coor{\R@*#1}{\R@*#2}m
-\xP@coor{\R@*#3}{\R@*#4}\xP@coor{\R@*#5}{\R@*#6}\xP@coor{\R@*#7}{\R@*#8}c}\vrule width\z@ height\R@ depth\R@
-\kern\dimexpr\R@*#7\relax
-}
-\xP@hook{cirrestrict@@}
-\newcommand*\xP@cirrestrict@@{\count@\z@\relax}
+\xP@endgobble
\endinput
%%
%% End of file `xypdf.sty'.