Debian Codegraph @

texmf-dist/tex/latex/hycolor/xcolor-patch.sty

raw
1 %%
2 %% This is file `xcolor-patch.sty',
3 %% generated with the docstrip utility.
4 %%
5 %% The original source files were:
6 %%
7 %% hycolor.dtx (with options: `xcolor')
8 %%
9 %% This is a generated file.
10 %%
11 %% Project: hycolor
12 %% Version: 2020-01-27 v1.10
13 %%
14 %% Copyright (C)
15 %% 2007-2011 Heiko Oberdiek
16 %% 2016-2020 Oberdiek Package Support Group
17 %%
18 %% This work may be distributed and/or modified under the
19 %% conditions of the LaTeX Project Public License, either
20 %% version 1.3c of this license or (at your option) any later
21 %% version. This version of this license is in
22 %% https://www.latex-project.org/lppl/lppl-1-3c.txt
23 %% and the latest version of this license is in
24 %% https://www.latex-project.org/lppl.txt
25 %% and version 1.3 or later is part of all distributions of
26 %% LaTeX version 2005/12/01 or later.
27 %%
28 %% This work has the LPPL maintenance status "maintained".
29 %%
30 %% The Current Maintainers of this work are
31 %% Heiko Oberdiek and the Oberdiek Package Support Group
32 %% https://github.com/ho-tex/hycolor/issues
33 %%
34 %% This work consists of the main source file hycolor.dtx
35 %% and the derived files
36 %% hycolor.sty, hycolor.pdf, hycolor.ins, hycolor.drv,
37 %% xcolor-patch.sty
38 %%
39 \NeedsTeXFormat{LaTeX2e}
40 \ProvidesPackage{xcolor-patch}[2020/01/27 v1.10 xcolor patch]
41 \RequirePackage{hopatch}
42 \hopatch@AfterPackage{xcolor}{%
43 \long\def\reserved@a#1#2#3{%
44 \long\def\@@tmp##1##2{%
45 \ifx#1##1%
46 \toks@{##2}%
47 \expandafter\remove@to@nnil
48 \else
49 \expandafter\@@tmp
50 \fi
51 }%
52 \@@tmp#2#1{#3}\@nnil\the\toks@
53 }%
54 \ifx\XC@ifxcase\reserved@a
55 \long\def\XC@ifxcase#1#2#3{%
56 \long\def\XC@if@##1##2{%
57 \ifx#1##1%
58 \toks@{##2}%
59 \expandafter\remove@to@nnil
60 \else
61 \expandafter\XC@if@
62 \fi
63 }%
64 \XC@if@#2#1{#3}\@nnil
65 \the\toks@
66 }%
67 \fi
68 \long\def\reserved@a#1#2#3{%
69 \long\def\@@tmp##1##2{%
70 \@expandtwoargs\in@{,#1,}{,##1,}%
71 \ifin@
72 \toks@{##2}%
73 \expandafter\remove@to@nnil
74 \else
75 \expandafter\@@tmp
76 \fi
77 }%
78 \@@tmp#2{#1}{#3}\@nnil
79 \the\toks@
80 }%
81 \ifx\XC@ifcase\reserved@a
82 \long\def\XC@ifcase#1#2#3{%
83 \long\def\XC@if@##1##2{%
84 \@expandtwoargs\in@{,#1,}{,##1,}%
85 \ifin@
86 \toks@{##2}%
87 \expandafter\remove@to@nnil
88 \else
89 \expandafter\XC@if@
90 \fi
91 }%
92 \XC@if@#2{#1}{#3}\@nnil
93 \the\toks@
94 }%
95 \fi
96 \def\reserved@a#1,{%
97 \XC@ifxcase\tm{%
98 \XC@mod@rgb{%
99 \XC@calcN{#1}\@@tmp
100 \edef\@@tmp{\@@tmp,\@@tmp,\@@tmp}%
101 }%
102 \XC@mod@cmy{%
103 \XC@calcC{#1}\@@tmp
104 \edef\@@tmp{\@@tmp,\@@tmp,\@@tmp}%
105 }%
106 \XC@mod@cmyk{%
107 \XC@calcC{#1}\@@tmp
108 \edef\@@tmp{0,0,0,\@@tmp}%
109 }%
110 \XC@mod@RGB{%
111 \edef\@@scl{\rangeRGB}%
112 \XC@calcM{#1}\@@tmp
113 \edef\@@tmp{\@@tmp,\@@tmp,\@@tmp}%
114 }%
115 \XC@mod@HTML{%
116 \edef\@@scl{\@cclv}%
117 \XC@calcM{#1}\@@tmp
118 \XC@calcH\@@tmp\@@tmp
119 \edef\@@tmp{\@@tmp\@@tmp\@@tmp}%
120 }%
121 \XC@mod@HSB{%
122 \edef\@@scl{\rangeHSB}%
123 \XC@calcM{#1}\@@tmp
124 \edef\@@tmp{0,0,\@@tmp}%
125 }%
126 \XC@mod@Gray{%
127 \edef\@@scl{\rangeGray}%
128 \XC@calcM{#1}\@@tmp
129 }%
130 }%
131 {%
132 \XC@calcN{#1}\@@tmp
133 \edef\@@tmp{0,0,\@@tmp}%
134 }%
135 }%
136 \ifx\XC@cnv@gray\reserved@a
137 \def\XC@cnv@gray#1,{%
138 \XC@ifxcase\tm{%
139 \XC@mod@rgb{%
140 \XC@calcN{#1}\@@tmp
141 \edef\@@tmp{\@@tmp,\@@tmp,\@@tmp}%
142 }%
143 \XC@mod@gray{}%
144 \XC@mod@cmy{%
145 \XC@calcC{#1}\@@tmp
146 \edef\@@tmp{\@@tmp,\@@tmp,\@@tmp}%
147 }%
148 \XC@mod@cmyk{%
149 \XC@calcC{#1}\@@tmp
150 \edef\@@tmp{0,0,0,\@@tmp}%
151 }%
152 \XC@mod@RGB{%
153 \edef\@@scl{\rangeRGB}%
154 \XC@calcM{#1}\@@tmp
155 \edef\@@tmp{\@@tmp,\@@tmp,\@@tmp}%
156 }%
157 \XC@mod@HTML{%
158 \edef\@@scl{\@cclv}%
159 \XC@calcM{#1}\@@tmp
160 \XC@calcH\@@tmp\@@tmp
161 \edef\@@tmp{\@@tmp\@@tmp\@@tmp}%
162 }%
163 \XC@mod@HSB{%
164 \edef\@@scl{\rangeHSB}%
165 \XC@calcM{#1}\@@tmp
166 \edef\@@tmp{0,0,\@@tmp}%
167 }%
168 \XC@mod@Gray{%
169 \edef\@@scl{\rangeGray}%
170 \XC@calcM{#1}\@@tmp
171 }%
172 }%
173 {%
174 \XC@calcN{#1}\@@tmp
175 \edef\@@tmp{0,0,\@@tmp}%
176 }%
177 }%
178 \fi
179 \@ifundefined{XC@frameb@x }{%
180 \expandafter\let\csname XC@frameb@x \endcsname\XC@frameb@x
181 \edef\XC@frameb@x{%
182 \noexpand\protect
183 \expandafter\noexpand\csname XC@frameb@x \endcsname
184 }%
185 \expandafter\ifx\csname XC@frameb@x \endcsname\@frameb@x
186 \let\@frameb@x\XC@frameb@x
187 \fi
188 }{}%
189 }
190 %% \section{Installation}
191 \endinput
192 %%
193 %% End of file `xcolor-patch.sty'.