blob: 224197f9b516d49463eadaa3fa333e602d1afd56 (
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
|
\ProvidesFileRCS $Header: /cvsroot/pgf/pgf/generic/pgf/systemlayer/pgfsys-dvipdfm.def,v 1.7 2005/09/30 07:14:03 tantau Exp $
% Copyright 2005 by Till Tantau <tantau@cs.tu-berlin.de>.
%
% This program can be redistributed and/or modified under the terms
% of the GNU Public License, version 2.
% Driver commands for dvipdfm
%
% Load common pdf commands:
%
\input pgfsys-common-pdf.def
%
% dvipdfm-specific stuff:
%
\def\pgfsys@invoke#1{\special{pdf: content Q #1 q}}
\def\pgfsys@hbox#1{%
\special{pdf: content Q q -1 0 0 -1 0 0 cm q}%
\special{pdf: content -1 0 0 -1 0 0 cm q}% translate to original coordinate system
\special{pdf: content 0 0 m W n q}% clip next stuff
{\hbox to 0pt{\pgf@selectfontorig.\hss}}% enforce font change
\special{pdf: content Q}% end of font change enforcement.
\wd#1=0pt%
\ht#1=0pt%
\dp#1=0pt%
\box#1
\special{pdf: content Q n Q}%
}
\def\pgfsys@beginpicture{%
\pgfsys@invoke{1 0 0 1 2000 2000 cm}%
\hbox to 0pt{\selectfont.\hss}%
\pgfsys@invoke{1 0 0 1 -2000 -2000 cm}%
\special{pdf: content q}}
\def\pgfsys@endpicture{%
\special{pdf: content n Q}%
}
\def\pgfsys@beginpurepicture{\special{pdf: content q}}
\def\pgf@sys@pdf@addtopageresources#1{%
\ifx\pgf@sys@pdf@obj\@undefined%
\global\let\pgf@sys@pdf@obj=\relax%
\special{pdf: obj @pgfopacities << >>}%
\fi%
\special{pdf: put @pgfopacities << #1 >>}%
\special{pdf: put @resources << /ExtGState @pgfopacities >>}%
}
\def\pgf@sys@pdf@readdtopageresources#1{%
\special{pdf: put @resources << /ExtGState @pgfopacities >>}%
}
\def\pgfsys@imagesuffixlist{pdf:jpg:jpeg:png}
\def\pgfsys@horishading#1#2#3{%
{%
\pgf@parsefunc{#3}%
\pgf@process{\pgfpoint{\pgf@max}{#2}}%
\edef\@temp{\noexpand\pgf@sys@atbeginpage{\special{pdf: beginxobj @pgfshade#1 width \the\pgf@max\space height \the\pgf@y}}}\@temp%
\edef\@temp{\noexpand\pgf@sys@atbeginpage{\special{pdf: put @resources <<
/Shading << /Sh << /ShadingType 2
/ColorSpace /DeviceRGB
/Domain [\pgf@pdfparseddomain]
/Coords [\pgf@doma\space0 \pgf@domb\space0]
/Function \pgf@pdfparsedfunction
/Extend [false false] >> >> >>}}}\@temp%
\pgf@sys@atbeginpage{\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}}%
}%
}
\def\pgfsys@vertshading#1#2#3{%
{%
\pgf@parsefunc{#3}%
\pgf@process{\pgfpoint{\pgf@max}{#2}}%
\edef\@temp{\noexpand\pgf@sys@atbeginpage{\special{pdf: beginxobj @pgfshade#1 width \the\pgf@y\space height \the\pgf@max\space}}}\@temp%
\edef\@temp{\noexpand\pgf@sys@atbeginpage{\special{pdf: put @resources <<
/Shading << /Sh << /ShadingType 2
/ColorSpace /DeviceRGB
/Domain [\pgf@pdfparseddomain]
/Coords [0 \pgf@doma\space0 \pgf@domb]
/Function \pgf@pdfparsedfunction
/Extend [false false] >> >> >>}}}\@temp%
\pgf@sys@atbeginpage{\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}}%
}%
}
\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%
\@tempdima=2\pgf@max\relax%
\edef\@temp{\noexpand\pgf@sys@atbeginpage{\special{pdf: beginxobj @pgfshade#1 width \the\@tempdima\space height \the\@tempdima}}}\@temp%
\edef\@temp{\noexpand\pgf@sys@atbeginpage{\special{pdf: put @resources <<
/Shading << /Sh << /ShadingType 3
/ColorSpace /DeviceRGB
/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%
\pgf@sys@atbeginpage{\special{pdf: content /Sh sh}%
\special{pdf: endxobj}}%
\expandafter\xdef\csname @pgfshading#1!\endcsname{%
\hbox to\the\@tempdima{\vbox to\the\@tempdima{\vfil\special{pdf: usexobj @pgfshade#1}}\hfil}}%
}%
}%
\def\pgf@sys@atbeginpage#1{\AtBeginDvi{#1}}
\AtBeginDocument{% hyperref hack
\providecommand\HyPL@EveryPage{}
\def\@begindvi{\unvbox\@begindvibox\HyPL@EveryPage}
}
\endinput
%%% Local Variables:
%%% mode: latex
%%% End:
|