diff options
Diffstat (limited to 'Master/texmf-dist/tex/generic/pgf/basiclayer/pgfcoreshade.code.tex')
-rw-r--r-- | Master/texmf-dist/tex/generic/pgf/basiclayer/pgfcoreshade.code.tex | 20 |
1 files changed, 17 insertions, 3 deletions
diff --git a/Master/texmf-dist/tex/generic/pgf/basiclayer/pgfcoreshade.code.tex b/Master/texmf-dist/tex/generic/pgf/basiclayer/pgfcoreshade.code.tex index e8225bb0225..d4b0e8bee74 100644 --- a/Master/texmf-dist/tex/generic/pgf/basiclayer/pgfcoreshade.code.tex +++ b/Master/texmf-dist/tex/generic/pgf/basiclayer/pgfcoreshade.code.tex @@ -7,7 +7,7 @@ % % See the file doc/generic/pgf/licenses/LICENSE for more details. -\ProvidesFileRCS $Header: /cvsroot/pgf/pgf/generic/pgf/basiclayer/pgfcoreshade.code.tex,v 1.9 2007/12/10 13:19:32 tantau Exp $ +\ProvidesFileRCS $Header: /cvsroot/pgf/pgf/generic/pgf/basiclayer/pgfcoreshade.code.tex,v 1.13 2008/11/23 16:07:47 ludewich Exp $ % % Parsing functions @@ -111,6 +111,14 @@ } +% Normalized a <color specification> argument for shadings into a +% series of rgb color specifications and writes the result into +% \pgf@rgbconv. +% +% Example: +% \pgf@convertrgbstring{rgb(0cm)=(1,0,0); rgb(2cm)=(0,1,0); rgb(4cm)=(0,0,1); gray(1cm)=(3); color(2cm)=(green); } +% -> +% \pgf@rgbconv = macro:->'rgb(0cm)=(1,0,0); rgb(2cm)=(0,1,0); rgb(4cm)=(0,0,1); rgb(1cm)=(3,3,3); rgb(2cm)=(0,1,0); ' \def\pgf@convertrgbstring#1{% \def\pgf@rgbconv{}% \pgf@converttorgb#1]% @@ -387,6 +395,12 @@ \expandafter\pgfutil@convertcolorspec\pgf@tempcolor{rgb}{\pgf@rgbcolor}% \expandafter\pgfshading@rgb\pgf@rgbcolor\relax% \edef#2{\pgf@sys@tonumber{\pgf@xa}\space\pgf@sys@tonumber{\pgf@xb}\space\pgf@sys@tonumber{\pgf@xc}\space}% + \c@pgf@counta\escapechar% + \escapechar-1\relax% + \expandafter\edef\csname\string#2red\endcsname{\pgf@sys@tonumber{\pgf@xa}\space}% + \expandafter\edef\csname\string#2green\endcsname{\pgf@sys@tonumber{\pgf@xb}\space}% + \expandafter\edef\csname\string#2blue\endcsname{\pgf@sys@tonumber{\pgf@xc}\space}% + \escapechar\c@pgf@counta% } \def\pgfshading@rgb#1,#2,#3\relax{% \pgf@xa=#1pt% @@ -531,8 +545,8 @@ \advance\pgf@xc by-\pgf@pathminx% \pgf@yc=\pgf@pathmaxy% \advance\pgf@yc by-\pgf@pathminy% - \pgf@xc=.02\pgf@xc% - \pgf@yc=.02\pgf@yc% + \pgf@xc=.01992528\pgf@xc% + \pgf@yc=.01992528\pgf@yc% \pgfsyssoftpath@invokecurrentpath% \pgfsys@clipnext% \pgfsys@discardpath% |