From a597ee865698eed2151f995ce7d9470b698f6b12 Mon Sep 17 00:00:00 2001 From: mertz Date: Tue, 21 Sep 2004 12:43:03 +0000 Subject: using classic colors #rrggbb rather than the X notation rgb:r/g/b when the system is not linux --- Perl/demos/Tk/demos/zinc_lib/color-x.pl | 3 +++ 1 file changed, 3 insertions(+) (limited to 'Perl') diff --git a/Perl/demos/Tk/demos/zinc_lib/color-x.pl b/Perl/demos/Tk/demos/zinc_lib/color-x.pl index ca6dcb5..62937b2 100644 --- a/Perl/demos/Tk/demos/zinc_lib/color-x.pl +++ b/Perl/demos/Tk/demos/zinc_lib/color-x.pl @@ -58,6 +58,9 @@ $zinc->add('text', 1, # we are using here the X explicit notation for rgb color # we could also have used CIE encoding. If interested, # please read the X man pages +my $gradient = ($^O eq 'linux') ? "=axial 0 | rgb:ffff/0/0;40 | rgb:0/ffff/0;40 50 | rgb:0/0/ffff;40" + : "=axial 0 | #ff0000;40 | #00ff00;40 50 | #0000ff;40"; + $zinc->add('rectangle', 1, [10, 210, 690, 300], -fillcolor => "=axial 0 | rgb:ffff/0/0;40 | rgb:0/ffff/0;40 50 | rgb:0/0/ffff;40", -filled => 1); $zinc->add('text', 1, -- cgit v1.1