[pgf-tikz] RGB colour model for plain TeX users
Henri Menke
henrimenke at gmail.com
Fri Nov 8 23:30:04 CET 2019
Dear Jim,
Thanks for the suggestion. I've opened a new issue on GitHub for it
and added it to the roadmap for the next release.
https://github.com/pgf-tikz/pgf/issues/772
Kind regards,
Henri
On 11/9/19 8:35 AM, Jim wrote:
> Hi,
>
> In Section 15.2 of the manual it says (under the "For plain TeX users"
> paragraph)
> Only the two color models gray and rgb are supported.
>
> In .../texmf-dist/tex/generic/pgf/utilities/pgfutil-plain.def it
> defines the macros
> \pgfutil at emu@rgb#1#2,#3,#4\@nil
> and
> \pgfutil at emu@gray#1#2,#3,#4\@nil
>
> I have used the following to implement the RGB model:
>
> \def\pgfutil at emu@RGB#1#2,#3,#4\@nil
> {
> \pgfmathsetmacro{\@red@}{#2/255}%
> \pgfmathsetmacro{\@green@}{#3/255}%
> \pgfmathsetmacro{\@blue@}{#4/255}%
> \expandafter\edef\csname\string\color@#1\endcsname
> {\noexpand\xcolor@ {}{}{rgb}{\@red@,\@green@,\@blue@}}
> }
>
> and it works in all the cases I have tried.
>
> Is there any chance of having this code (or better, but equivalent code)
> added to pgfutil-plain.def, and the note in Section 15.2 of the manual
> updated?
>
> Thanks.
>
> Jim
More information about the pgf-tikz
mailing list