Debian Codegraph @

texmf-dist/tex/generic/xypic/xyps-c.tex

raw
1 %% xyps-c.tex from $Id: xyps-c.doc,v 3.11 2011/03/14 20:14:00 krisrose Exp $
2 %%
3 %% Xy-pic ``Colour extension'' PostScript backend support.
4 %% Copyright (c) 1993-1996 Ross Moore <[email protected]>
5 %%
6 %% This file is part of the Xy-pic package for graphs and diagrams in TeX.
7 %% See the companion README and INSTALL files for further information.
8 %% Copyright (c) 1991-2011 Kristoffer H. Rose <[email protected]>
9 %%
10 %% The Xy-pic package is free software; you can redistribute it and/or modify
11 %% it under the terms of the GNU General Public License as published by the
12 %% Free Software Foundation; either version 2 of the License, or (at your
13 %% option) any later version.
14 %%
15 %% The Xy-pic package is distributed in the hope that it will be useful, but
16 %% WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
17 %% or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
18 %% for more details.
19 %%
20 %% You should have received a copy of the GNU General Public License along
21 %% with this package; if not, see http://www.gnu.org/licenses/.
22 %%
23 %% As a special exception, you may use this file and all files derived
24 %% from it without restrictions. This special exception was added with
25 %% version 3.7 of Xy-pic.
26 %%
27 \expandafter\ifx\csname xyps-cloaded\endcsname\empty
28 \message{not reloaded}\endinput \fi
29 \expandafter\let\csname xyps-cloaded\endcsname=\empty \xycatcodes
30 \expandafter\ifx \csname xyps-sloaded\endcsname\empty\else
31 \xyinputorelse@{xyps-s}{\xyerror@{Could not load xyps-s}{}}%
32 \xycatcodes\fi
33 \xydef@\UsePScolor{\installPScolor@}
34 \xydef@\NoPScolor{\UnloadColor@}
35 \xydef@\installPScolor@{\installPSstyle@
36 \let\xymath@=\xyPSmath@ \let\xynomath@=\xyPSnomath@
37 \let\checkxyPScolor@=\checkxyPScolor@@
38 \let\xycolor@@=\xyPScolor@@
39 \xystandardcolors@
40 \xyuncatcodes }
41 \xydef@\xyPSmath@{\hbox\bgroup\dimen@=.55ex \checkxyPScolor@ \xyinside@}
42 \xydef@\xyPSnomath@{\hbox\bgroup\dimen@=\z@ \checkxyPScolor@ \xyinside@}
43 \xydef@\checkxyPScolor@@{\xycolor@raw@@{}\let\checkxyPScolor@=\relax}
44 \xylet@\checkxyPScolor@=\relax
45 \xydef@\xyPSnewcolor@#1#2#3#4#5{%
46 \expandafter\DN@\expandafter{\csname shape [#1]\endcsname}%
47 \DNii@{\relax}\ifx\next@\nextii@\newxycolor{#1}{}\relax\fi
48 \DNii@{#4}\ifx\nextii@\empty
49 \expandafter\DNii@\expandafter{\csname xyPSshape@#1@\endcsname}%
50 \expandafter\def\nextii@{\xyPScolor@{#2 #3}}\else
51 \expandafter\DNii@\expandafter{\csname xyPSshape@#1@\endcsname}%
52 \expandafter\def\nextii@{\xyPScolor@{#4}}\fi
53 \ifx\nextii@\empty\expandafter\def\next@{\xyPSnotimplemented@@`#1'@@}%
54 \else
55 \edef\tmp@{\noexpand\let\expandafter\noexpand\next@
56 \expandafter\noexpand\nextii@}\expandafter\tmp@\fi }
57 \xydef@\xyPScolor@{\ifPSspecials@\expandafter\xyPScolor@@
58 \else\expandafter\eat@\fi}
59 \xydef@\xyPScolor@@#1{\bgroup \checkXyStyle@
60 \def\preStyle@@{\expandafter\addtostyletoks@\expandafter{\xyPSpre@}}%
61 \def\postStyle@@{\expandafter\addtostyletoks@\expandafter{\xyPSpost@}}%
62 \let\modPSboxz@=\modXYstyle@ \xyPS@color@@{#1}%
63 \toks@={\egroup\let\xy@style@=\relax \def\Drop@@}%
64 \expandafter\addtotoks@\expandafter{\expandafter{\Drop@@}\def\Connect@@}%
65 \expandafter\addtotoks@\expandafter{\expandafter{\Connect@@}}%
66 \the\toks@ }
67 \xydef@\xyPS@color@@#1{\xyPSsplitPS@{{#1}cc}{}}
68 \xydef@\xycolor@raw@@#1{\PSraw@@{xyc}}
69 \endinput