summaryrefslogtreecommitdiff
path: root/macros/generic/diagrams/xypic/texinputs/xypdf-ro.tex
blob: d0bcf79638d0c1e9b527c3c1b9990dc8613adcef (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
%%
%% This is file `xypdf-ro.tex',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% xypdf.dtx  (with options: `rotate')
%% 
%% The xypdf package for TeX and LaTeX
%% Copyright (c) 2010 by Daniel Müllner (M\"ullner)
%% <http://math.stanford.edu/~muellner>
%% --------------------------------------------------------------------------
%% 
%% This program is free software: you can redistribute it and/or modify it
%% under the terms of the GNU General Public License as published by the Free
%% Software Foundation, either version 2 of the License, or (at your option)
%% any later version.
%% 
%% This program is distributed in the hope that it will be useful, but
%% WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
%% or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
%% for more details.
%% 
%% The GNU General Public License is available at
%% <http://www.gnu.org/licenses/>.
%% 
%% --------------------------------------------------------------------------
%% 
%% This file is part of the xypdf package for TeX and LaTeX2e. The xypdf
%% package may be distributed and/or modified under the conditions of the
%% GNU General Public License as published by the Free Software Foundation,
%% either version 2 of the License, or (at your option) any later version.
%% The distribution consists of the following files:
%% 
%%    xypdf.dtx  -  Documented source code
%%    xypdf.ins  -  Installation script
%%    xypdf.pdf  -  Documentation (generated from xypdf.dtx)
%% 
%% The files with the TeX code are generated by the following command:
%% 
%%    latex xypdf.ins
%% 
%% This generates the files xypdf.tex, xypdf-co.tex, xypdf-cu.tex,
%% xypdf-fr.tex, xypdf-li.tex and xypdf-ro.tex.
%% 
%% --------------------------------------------------------------------------
%% 
%% The xypdf package improves the output quality of the Xy-pic package when
%% PDF documents are generated. It produces generic PDF code for graphical
%% elements like lines, curves and circles instead of approximating these
%% elements with glyphs in special fonts as the original Xy-pic package does.
%% The xypdf package works with both TeX and LaTeX in the occurrences of
%% pdfTeX, XeTeX and eTeX with dvipdfm(x) to generate PDF files. It is being
%% integrated and distributed together with Xy-pic, starting with Xy-pic
%% version 3.8.
%% 
%% The copyright for the xypdf package is by its author, Daniel Müllner
%% (Muellner, M\"ullner).
%% 
\xycatcodes
\expandafter\let\csname xypdf-ro@loaded\endcsname\@empty
\xP@hook{rotate}{xyscale@@}
\newcommand*\xP@xyscale@@[2]{\setboxz@h{\hskip\L@c
\hskip-\R@p
\lower\U@p\hbox{\xP@cm{#1}00{#2}{\raise\U@p\hb@xt@\z@{\hskip-\L@c\hskip\R@p\boxz@\hss}}}}\global\let\xP@lastpattern\@empty
}
\xP@hook{rotate}{xyRotate@@}
\newcommand\xP@xyRotate@@{\xP@rotate@\xP@trigfromdir}
\xP@hook{rotate}{doSpecialRotate@@}
\@ifdefinable\xP@doSpecialRotate@@\relax
\def\xP@doSpecialRotate@@#1@@{\xP@rotate@\xP@trig{#1}}
\newcommand*\xP@rotate@[2]{\setboxz@h{#1{#2}\hskip\L@c
\hskip-\R@p
\lower\U@p\hbox{\xP@cm\cosDirection\sinDirection
{\if-\sinDirection\else-\sinDirection\fi}\cosDirection
{\raise\U@p\hb@xt@\z@{\hskip-\L@c\hskip\R@p\boxz@\hss}}}}\global\let\xP@lastpattern\@empty
}
\newcommand*\xP@trig[1]{\@tempdima\dimexpr#1pt\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
}
\xyendinput





%%
%% End of file `xypdf-ro.tex'.