diff options
author | cvs2svn | 2005-06-10 10:29:11 +0000 |
---|---|---|
committer | cvs2svn | 2005-06-10 10:29:11 +0000 |
commit | 960cdf29197bc3f5922110cf26627aa9709ac79b (patch) | |
tree | 7d6e4a472376b203d21826c2230b4a8c6a9024bd /sandbox/testrelief.pl | |
parent | 3fc9c4bc1d6f70db41ad418992bf3d461059d3c0 (diff) | |
download | tkzinc-960cdf29197bc3f5922110cf26627aa9709ac79b.zip tkzinc-960cdf29197bc3f5922110cf26627aa9709ac79b.tar.gz tkzinc-960cdf29197bc3f5922110cf26627aa9709ac79b.tar.bz2 tkzinc-960cdf29197bc3f5922110cf26627aa9709ac79b.tar.xz |
This commit was manufactured by cvs2svn to create branch 'bogue40'.
Diffstat (limited to 'sandbox/testrelief.pl')
-rw-r--r-- | sandbox/testrelief.pl | 73 |
1 files changed, 0 insertions, 73 deletions
diff --git a/sandbox/testrelief.pl b/sandbox/testrelief.pl deleted file mode 100644 index 79c9a31..0000000 --- a/sandbox/testrelief.pl +++ /dev/null @@ -1,73 +0,0 @@ -#!/usr/bin/perl -w - -use Tk; -use Tk::Zinc; -use Controls; - -$top = 1; -$lw = 8; - -$mw = MainWindow->new(); -$zinc = $mw->Zinc(-backcolor => 'gray', - -relief => 'sunken', - -lightangle => 120, - -render => 1); -$zinc->pack(-expand => 1, - -fill => 'both'); -$zinc->configure(-width => 1024, - -height => 800); -$zinc->scale($top, 1, -1); - -$view = $zinc->add('group', $top, -tags => 'controls'); - -sub polypoints { - ($ox, $oy, $rad, $n, $startangle) = @_; - - $step = 2 * 3.14159 / $n; - $startangle = $startangle*3.14159/180; - $coords = []; - for ($i = 0; $i < $n; $i++) { - $x = $ox + ($rad * cos($i * $step + $startangle)); - $y = $oy + ($rad * sin($i * $step + $startangle)); - push(@{$coords}, $x, $y); - } - push(@{$coords}, $coords->[0], $coords->[1]); - return $coords -} - -$zinc->add('curve', $view, polypoints(200, -200, 100, 40, 0), - -relief => 'raised', - -linewidth => $lw, - -smoothrelief => 1, - -fillcolor => 'lightblue', - -linecolor => 'lightblue', - -filled => 1); - -$zinc->add('curve', $view, polypoints(450, -200, 100, 40, 0), - -relief => 'raised', - -linewidth => $lw, - -smoothrelief => 1, - -fillcolor => 'tan', - -linecolor => 'tan', - -filled => 1); - -$zinc->add('curve', $view, polypoints(700, -200, 100, 40, 0), - -relief => 'sunken', - -linewidth => $lw, - -smoothrelief => 1, - -fillcolor => 'tan', - -linecolor => 'tan', - -closed => 1, - -filled => 1); - -$zinc->add('curve', $view, polypoints(200, -450, 100, 7, -45), - -relief => 'sunken', - -linewidth => $lw, - -fillcolor => 'tan', - -linecolor => 'tan', - -filled => 1); - - -new Controls($zinc); -MainLoop(); - |