summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/pgf-cmykshadings/pgfsys-cmykshadings-dvipdfm.def
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2018-10-23 20:44:07 +0000
committerKarl Berry <karl@freefriends.org>2018-10-23 20:44:07 +0000
commitb2d85c17c9d9577a0395372219abcf13949d50a7 (patch)
tree32d101fe009b9bdf39e8002113dcd72749fa0854 /Master/texmf-dist/tex/latex/pgf-cmykshadings/pgfsys-cmykshadings-dvipdfm.def
parentba8ca340d0f3c38699715adddc605dde56ee9ab2 (diff)
pgf-cmykshadings (23oct18)
git-svn-id: svn://tug.org/texlive/trunk@48976 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/pgf-cmykshadings/pgfsys-cmykshadings-dvipdfm.def')
-rw-r--r--Master/texmf-dist/tex/latex/pgf-cmykshadings/pgfsys-cmykshadings-dvipdfm.def132
1 files changed, 132 insertions, 0 deletions
diff --git a/Master/texmf-dist/tex/latex/pgf-cmykshadings/pgfsys-cmykshadings-dvipdfm.def b/Master/texmf-dist/tex/latex/pgf-cmykshadings/pgfsys-cmykshadings-dvipdfm.def
new file mode 100644
index 00000000000..169e4a2bf7a
--- /dev/null
+++ b/Master/texmf-dist/tex/latex/pgf-cmykshadings/pgfsys-cmykshadings-dvipdfm.def
@@ -0,0 +1,132 @@
+%%
+%% This is file `pgfsys-cmykshadings-dvipdfm.def',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% pgf-cmykshadings.dtx (with options: `dvipdfm-driver')
+%%
+%% This is a generated file.
+%%
+%% Copyright (c) 2018 David Purton <dcpurton@marshwiggle.net>
+%%
+%% This work may be distributed and/or modified under the conditions of
+%% the LaTeX Project Public License, either version 1.3c of this license
+%% or (at your option) any later version. The latest version of this
+%% license is in
+%% http://www.latex-project.org/lppl.txt
+%% and version 1.3c or later is part of all distributions of LaTeX
+%% version 2005/12/01 or later.
+%%
+%% This work is "maintained" (as per the LPPL maintenance status)
+%% by David Purton.
+%%
+%% This work consists of the files pgf-cmykshadings.ins,
+%% pgf-cmykshadings.dtx, README.md, and the derived files
+%% - pgf-cmykshadings.sty
+%% - pgfsys-cmykshadings-pdftex.def
+%% - pgfsys-cmykshadgins-xetex.def
+%% - pgfsys-cmykshadings-luatex.def
+%% - pgfsys-cmykshadings-dvipdfmx.def
+%% - pgfsys-cmykshadings-dvipdfm.def
+%% - pgfsys-cmykshadings-dvips.def
+%% - pgfsys-cmykshadings-textures.def
+%% - pgfsys-cmykshadings-vtex.def
+%% - pgfsys-cmykshadings-common-postscript.def
+%% - pgf-cmykshadings.pdf
+%%
+%%
+%% Substantial parts of the code for this package are taken from the pgf package
+%% file pgfcoreshade.code.tex, along with the driver files pgfsys-*.def, copyright
+%% (c) 2006 Till Tantau and then slightly modified to support CMYK and grayscale
+%% shadings.
+%%
+\ProvidesFile{pgfsys-cmykshadings-dvipdfm.def}%
+ [2018/10/18 CMYK shadings support for PGF dvipdfm driver (DCP)]
+\def\pgfsys@horishading#1#2#3{%
+ {%
+ \pgf@parsefunc{#3}%
+ \pgf@process{\pgfpoint{\pgf@max}{#2}}%
+ \edef\@temp{\noexpand\pgfutil@insertatbegincurrentpage{%
+ \special{pdf: beginxobj @pgfshade#1 width \the\pgf@max\space
+ height \the\pgf@y}}}\@temp%
+ \edef\@temp{\noexpand\pgfutil@insertatbegincurrentpage{%
+ \special{pdf: put @resources <<
+ /Shading << /Sh << /ShadingType 2
+ /ColorSpace \pgf@shading@device\space
+ /Domain [\pgf@pdfparseddomain]
+ /Coords [\pgf@doma\space0 \pgf@domb\space0]
+ /Function \pgf@pdfparsedfunction
+ /Extend [false false] >> >> >>}}}\@temp% <<
+ \pgfutil@insertatbegincurrentpage{\special{pdf: content /Sh sh}%
+ \special{pdf: endxobj}}%
+ \expandafter\xdef\csname @pgfshading#1!\endcsname{%
+ \hbox to\the\pgf@max{\vbox to#2{%
+ \vfil\special{pdf: usexobj @pgfshade#1}}\hfil}}%
+ \expandafter\xdef\csname @pgfshading#1@model!\endcsname{%
+ \pgf@shading@model}%
+ }%
+}
+\def\pgfsys@vertshading#1#2#3{%
+ {%
+ \pgf@parsefunc{#3}%
+ \pgf@process{\pgfpoint{\pgf@max}{#2}}%
+ \edef\@temp{\noexpand\pgfutil@insertatbegincurrentpage{%
+ \special{pdf: beginxobj @pgfshade#1 width \the\pgf@y\space
+ height \the\pgf@max\space}}}\@temp%
+ \edef\@temp{\noexpand\pgfutil@insertatbegincurrentpage{%
+ \special{pdf: put @resources <<
+ /Shading << /Sh << /ShadingType 2
+ /ColorSpace \pgf@shading@device\space
+ /Domain [\pgf@pdfparseddomain]
+ /Coords [0 \pgf@doma\space0 \pgf@domb]
+ /Function \pgf@pdfparsedfunction
+ /Extend [false false] >> >> >>}}}\@temp% <<
+ \pgfutil@insertatbegincurrentpage{\special{pdf: content /Sh sh}%
+ \special{pdf: endxobj}}%
+ \expandafter\xdef\csname @pgfshading#1!\endcsname{%
+ \hbox to#2{\vbox to\the\pgf@max{\vfil\special{%
+ pdf: usexobj @pgfshade#1}}\hfil}}%
+ \expandafter\xdef\csname @pgfshading#1@model!\endcsname{%
+ \pgf@shading@model}%
+ }%
+}
+\def\pgfsys@radialshading#1#2#3{%
+ {%
+ \pgf@parsefunc{#3}%
+ \pgf@process{#2}%
+ \pgf@xa=\pgf@x%
+ \pgf@ya=\pgf@y%
+ \pgf@process{\pgfpoint{\pgf@max}{\pgf@max}}%
+ \advance\pgf@xa by \pgf@x\relax%
+ \advance\pgf@ya by \pgf@y\relax%
+ \pgf@sys@bp@correct{\pgf@x}%
+ \pgf@sys@bp@correct{\pgf@y}%
+ \pgf@sys@bp@correct{\pgf@xa}%
+ \pgf@sys@bp@correct{\pgf@ya}%
+ \pgfutil@tempdima=2\pgf@max\relax%
+ \edef\@temp{\noexpand\pgfutil@insertatbegincurrentpage{%
+ \special{pdf: beginxobj @pgfshade#1 width
+ \the\pgfutil@tempdima\space height \the\pgfutil@tempdima}}}\@temp%
+ \edef\@temp{\noexpand\pgfutil@insertatbegincurrentpage{%
+ \special{pdf: put @resources <<
+ /Shading << /Sh << /ShadingType 3
+ /ColorSpace \pgf@shading@device\space
+ /Domain [\pgf@pdfparseddomain]
+ /Coords [\pgf@sys@tonumber{\pgf@xa} \pgf@sys@tonumber{\pgf@ya}
+ \pgf@doma\space \pgf@sys@tonumber{\pgf@x} \pgf@sys@tonumber{\pgf@y}
+ \pgf@domb]
+ /Function \pgf@pdfparsedfunction
+ /Extend [true false] >> >> >>}}}\@temp% <<
+ \pgfutil@insertatbegincurrentpage{\special{pdf: content /Sh sh}%
+ \special{pdf: endxobj}}%
+ \expandafter\xdef\csname @pgfshading#1!\endcsname{%
+ \hbox to\the\pgfutil@tempdima{\vbox to\the\pgfutil@tempdima{%
+ \vfil\special{pdf: usexobj @pgfshade#1}}\hfil}}%
+ \expandafter\xdef\csname @pgfshading#1@model!\endcsname{%
+ \pgf@shading@model}%
+ }%
+}%
+%%
+%%
+%% End of file `pgfsys-cmykshadings-dvipdfm.def'.