aboutsummaryrefslogtreecommitdiff
path: root/Perl/demos/Tk
diff options
context:
space:
mode:
Diffstat (limited to 'Perl/demos/Tk')
-rw-r--r--Perl/demos/Tk/demos/zinc_contrib_lib/README1
-rw-r--r--Perl/demos/Tk/demos/zinc_contrib_lib/TripleRotatingWheel.pl445
-rw-r--r--Perl/demos/Tk/demos/zinc_data/background_texture.gifbin19979 -> 0 bytes
-rw-r--r--Perl/demos/Tk/demos/zinc_data/hegias_parouest_TE.vidbin9216 -> 0 bytes
-rw-r--r--Perl/demos/Tk/demos/zinc_data/paper-grey.gifbin1540 -> 0 bytes
-rw-r--r--Perl/demos/Tk/demos/zinc_data/paper-grey1.gifbin1540 -> 0 bytes
-rw-r--r--Perl/demos/Tk/demos/zinc_data/paper.gifbin1529 -> 0 bytes
-rw-r--r--Perl/demos/Tk/demos/zinc_data/stripped_texture.gifbin123 -> 0 bytes
-rw-r--r--Perl/demos/Tk/demos/zinc_data/videomap_orlybin67584 -> 0 bytes
-rw-r--r--Perl/demos/Tk/demos/zinc_data/videomap_paris-w_90_2bin8192 -> 0 bytes
-rw-r--r--Perl/demos/Tk/demos/zinc_data/zinc.gifbin793 -> 0 bytes
-rw-r--r--Perl/demos/Tk/demos/zinc_data/zinc_anti.gifbin1461 -> 0 bytes
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/MagicLens.pl325
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/Zetris.pl972
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/all_options.pl154
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/atomic-groups.pl221
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/clipping.pl150
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/color-circular.pl75
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/color-path-and-conic.pl78
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/color-x.pl94
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/color-y.pl91
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/contours.pl202
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/counter.pl440
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/curve_bezier.pl221
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/fillrule.pl101
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/groups_in_ATC_strips.pl910
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/groups_priority.pl261
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/icon_zoom_resize.pl157
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/items.pl187
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/labelformat.pl111
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/lines.pl96
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/mapinfo.pl130
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/path_tags.pl357
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/rotation.pl124
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/simple_interaction_track.pl269
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/simpleradar.pl489
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/testGraphics.pl1845
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/textInput.pl98
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/tiger.pl554
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/tkZincLogo.pl165
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/transforms.pl568
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/translation.pl144
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/triangles.pl58
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/wheelOfFortune.pl374
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/window-contours.pl112
-rw-r--r--Perl/demos/Tk/demos/zinc_lib/zoom.pl180
-rw-r--r--Perl/demos/Tk/demos/zinc_pm/SimpleRadarControls.pm235
47 files changed, 0 insertions, 10994 deletions
diff --git a/Perl/demos/Tk/demos/zinc_contrib_lib/README b/Perl/demos/Tk/demos/zinc_contrib_lib/README
deleted file mode 100644
index 4decc6a..0000000
--- a/Perl/demos/Tk/demos/zinc_contrib_lib/README
+++ /dev/null
@@ -1 +0,0 @@
-This directory is for deposing zinc demos contribs \ No newline at end of file
diff --git a/Perl/demos/Tk/demos/zinc_contrib_lib/TripleRotatingWheel.pl b/Perl/demos/Tk/demos/zinc_contrib_lib/TripleRotatingWheel.pl
deleted file mode 100644
index 42bb2d1..0000000
--- a/Perl/demos/Tk/demos/zinc_contrib_lib/TripleRotatingWheel.pl
+++ /dev/null
@@ -1,445 +0,0 @@
-#!/usr/bin/perl
-# TripleRotatingWheel gambling game contributed by "zentara"
-
-# Idea derived from the wheelOfFortune.pl demo by D. Etienne etienne@cena.fr
-# $Id$
-
-
-use Tk;
-use Tk::Zinc;
-
-my @win =(); # an array to store winning wheel values, can range from
- # () to (1,1,1)
-
-# We create a classical root widget called MainWindow; then we create Zinc
-# widget child with size, color and relief attributes, and we display it using
-# the geometry manager called 'pack'.
-my $mw = MainWindow->new;
-$mw->geometry("700x600");
-
-$mw->resizable(0,0);
-
-my $zinc = $mw->Zinc(-width => 700, -height => 565,
- -backcolor => 'black',
- -borderwidth => 3, -relief => 'sunken');
-$zinc->pack;
-
-# Then we create a gray filled rectangle, in which we will display explain text.
-$zinc->add('rectangle', 1 , [200, 400, 490, 490],
- -linewidth => 2,
- -filled => 1,
- -fillcolor => 'SkyBlue',
- );
-my $text = $zinc->add('text', 1,
- -position => [350, 445],
- -anchor => 'center',
- );
-
-$zinc->add('rectangle', 1 , [250,275,450,325], #(xpos1,ypos1,xpos2,ypos2)
- -linewidth => 2,
- -filled => 1,
- -fillcolor => 'Orange',
- );
-
-my $wintext = $zinc->add('text', 1,
- -position => [350, 300],
- -anchor => 'center',
- );
-
-#create winning wheel markers
-#create first triangle, then clone and translate
-my $tr1 = $zinc->add('triangles', 1,
- [0,20,20,20,10,50],
- -fan => 1,
- -colors => 'Orange',
- -visible => 1,
- );
-my $tr2 = $zinc->clone($tr1);
-my $tr3 = $zinc->clone($tr1);
-$zinc->translate($tr1,130,0);
-$zinc->translate($tr2,340,0);
-$zinc->translate($tr3,550,0);
-
-
-
-# Create the Wheel object (see Wheel.pm)
-my $wheel1 = Wheel->new($zinc, 350, 500, 100); #start xpos,ypos,mag
-my $wheel2 = Wheel->new($zinc, 350, 500, 100);
-my $wheel3 = Wheel->new($zinc, 350, 500, 100);
-
-# Display comment
-&comment("Strike any key to begin");
-&wincomment("READY");
-
-# Create Tk binding
-$mw->Tk::bind('<Key>', \&openmode);
-
-
-MainLoop;
-
-# Callback bound to '<Key>' event when wheel is unmapped
-sub openmode {
- # set binding to unmap the wheel
- $mw->Tk::bind('<Key>', \&closemode);
- # set binding to rotate the hand
- $zinc->bind($wheel1, '<1>', sub {spin()});
- $zinc->bind($wheel2, '<1>', sub {spin()});
- $zinc->bind($wheel3, '<1>', sub {spin()});
- # map the wheel
- $wheel1->show(140, 150);
- $wheel2->show(350, 150);
- $wheel3->show(560, 150);
-
- # and then inform user
- &comment("Click on any wheel to play.\n".
- "Strike any key to hide the wheels.");
-}
-
-sub spin {
- return if $wheel1->ismoving;
- return if $wheel2->ismoving;
- return if $wheel3->ismoving;
-
- @win=();
- &wincomment("PLAYING");
- $wheel1->rotatewheel(int rand(360));
- $wheel2->rotatewheel(int rand(360));
- $wheel3->rotatewheel(int rand(360));
-# print "\@win->@win\n";
- }
-
-
-# Callback bound to '<Key>' event when wheel is already mapped
-sub closemode {
- return if $wheel1->ismoving;
- return if $wheel2->ismoving;
- return if $wheel3->ismoving;
-
- # set binding to map the wheel
- $mw->Tk::bind('<Key>', \&openmode);
- # unmap the wheel
- $wheel1->hide(350, 400);
- $wheel2->hide(350, 400);
- $wheel3->hide(350, 400);
- # and then inform user
- &comment("Strike any key to show the wheel");
-}
-
-# Just display comment
-sub comment {
- my $string = shift;
- $zinc->itemconfigure($text, -text => $string);
-}
-
-# display winning comment
-sub wincomment {
- my $string = shift;
- $zinc->itemconfigure($wintext, -text => $string);
-}
-
-sub displaywin {
- if($#win == -1){&wincomment("NO WIN")}
- if($#win == 0){&wincomment("SINGLE")}
- if($#win == 1){&wincomment("DOUBLE")}
- if($#win == 2){&wincomment("TRIPLE")}
-
- #restore disabled mouse click for next spin
- $zinc->bind($wheel1, '<1>', sub {spin()});
- $zinc->bind($wheel2, '<1>', sub {spin()});
- $zinc->bind($wheel3, '<1>', sub {spin()});
-}
-
-#=============================================================================
-# Wheel Class
-#=============================================================================
-package Wheel;
-
-use strict 'vars';
-use Carp;
-#====================
-# Object constructor
-#====================
-sub new {
- my ($proto, $widget, $x, $y, $radius) = @_;
-
- # object attributes
- my $self = {
- 'widget' => $widget, # widget reference
- 'origin' => [$x, $y], # origin coordinates
- 'radius' => $radius, # wheel radius
- 'topgroup' => undef, # top Group item
- 'itemclip' => undef, # id of item which clips the wheel
- 'angle' => 0, # delta angle
- 'stepsnumber' => 20, # animations parameters
- 'afterdelay' => 30,
- 'shrinkrate' => 0.8, # zoom parameters
- 'zoomrate' => 1.1,
-
- };
- bless $self;
-
- # First, we create a new Group item for the wheel. Why a Group item ?
- # At least two reasons. Wheel object consists of several Zinc items,
- # we'll see below; it moves when it is mapped or unmapped, grows when
- # you hit the jackpot. So, it's more easy to apply such transformations
- # to a structured items set, using Group capability, rather than apply
- # to each item separately or using canvas-like Tags mechanism.
- # Second reason refers to clipping. When it is mapped or unmapped, wheel
- # object is drawn inside a circle with variant radius; clipping is a
- # specific property of Group item
-
- # That's why we create a Group item in the top group, and set its
- # coordinates.
- $self->{topgroup} = $widget->add('group', 1, -visible => 0);
- $widget->coords($self->{topgroup}, [$x,$y]);
-
-#print " start widget coords-> $x $y\n";
-
- # All the following items will be created in this group...
- # Create the invisible Arc item used to clip the wheel, centered on the
- # group origin.
- $self->{itemclip} = $widget->add('arc', $self->{topgroup},
- [-$radius, -$radius, $radius, $radius],
- -visible => 0,
- );
- $widget->itemconfigure($self->{topgroup}, -clip => $self->{itemclip});
-
- # Create the wheel with 6 filled Arc items centered on the group origin
- my $i = 0;
- for my $color (qw(magenta blue cyan green yellow red)) {
- $widget->add('arc', $self->{topgroup},
- [-$radius, -$radius, $radius, $radius],
- -visible => 1,
- -filled => 1,
- -closed => 1,
- -extent => 60,
- -pieslice => 1,
- -fillcolor => $color,
- -linewidth => 1,
- -startangle => 60*$i ,
- -tags => [$self],
- );
- $i++;
- }
-
- # Create the Text item representing the jackpot.
- $widget->add('text', $self->{topgroup},
- -position => [0, -$radius+20],
- -font =>
- '-adobe-helvetica-bold-o-normal--34-240-100-100-p-182-iso8859-1',
- -anchor => 'center',
- -text => "\$",
- );
-
-
- # Then we unmap the wheel; in fact, Group item is translated and its
- # clipping circle is shrunk to a point.
- $self->_clipAndTranslate($self->{shrinkrate}**$self->{stepsnumber});
- return $self;
-}
-
-#================
-# Public methods
-#================
-
-# Return 1 if wheel is moving (opening or closing animation)
-sub ismoving {
- my $self = shift;
- return 1 if $self->{opening} or $self->{closing} or $self->{turning};
-}
-
-# Display wheel with animation effect
-sub show {
- my ($self, $x, $y) = @_;
- # simple lock management
- return if $self->{opening} or $self->{closing};
- $self->{opening} = 1;
- # start animation
- $self->_open($x, $y, 0);
-}
-
-
-# Unmap wheel with animation effect
-sub hide {
- my ($self, $x, $y) = @_;
- # simple lock management
- return if $self->{opening} or $self->{closing};
- $self->{closing} = 1;
- # start animation
- $self->_close($x, $y, 0);
-}
-
-
-# Just rotate the hand with animation effect.
-sub rotatewheel {
- my $self = shift;
- #print "wheel-> $self->{topgroup}";
- my $angle = shift;
-#print " angle->$angle\n";
-
- return if $self->{turning};
-
-#prevent "double-clicking", so mouse is disabled
-#until current play is over
-$zinc->bind($wheel1, '<1>', sub {});
-$zinc->bind($wheel2, '<1>', sub {});
-$zinc->bind($wheel3, '<1>', sub {});
-
- $angle = 0 unless $angle;
- my $oldangle = $self->{angle};
- $self->{angle} = $angle;
-
- if ((330 < $angle)||($angle < 30)) {
- $self->{fortune} = 1;
- push (@win, $self->{fortune});
- }
- $self->_rotatewheel(2*3.1416*($angle + 1440 - $oldangle)/360);
- #the 1440 above gives at least 2 full spins each play
-}
-
-#=================
-# Private methods
-#=================
-
-# Generate opening animation; see below _clipAndTranslate method for
-# Zinc specific use.
-sub _open {
- my ($self, $x, $y, $cnt) = @_;
- my $widget = $self->{widget};
- my $group = $self->{topgroup};
- # first step of animation
- if ($cnt == 0) {
- $widget->itemconfigure($group, -visible => 1);
- my @pos = $widget->coords($group);
- $x = ($x - $pos[0])/$self->{stepsnumber};
- $y = ($y - $pos[1])/$self->{stepsnumber};
- # last step
- } elsif ($cnt == $self->{stepsnumber}) {
- $self->{opening} = undef;
- return;
- }
- $cnt++;
- # move and grow the wheel
- $self->_clipAndTranslate(1/$self->{shrinkrate}, $x, $y);
- # process the animation using the 'after' Tk defering method
- $widget->after($self->{afterdelay}, sub {$self->_open($x, $y, $cnt)});
-}
-
-
-# Generate closing animation; see below _clipAndTranslate method for
-# Zinc specific use.
-sub _close {
- my ($self, $x, $y, $cnt) = @_;
- my $widget = $self->{widget};
- my $group = $self->{topgroup};
- # first step of animation
- if ($cnt == 0) {
- my @pos = $widget->coords($group);
- $x = ($x - $pos[0])/$self->{stepsnumber};
- $y = ($y - $pos[1])/$self->{stepsnumber};
- # last step
- } elsif ($cnt == $self->{stepsnumber}) {
- $widget->itemconfigure($group, -visible => 0);
- $self->{closing} = undef;
- return;
- }
- $cnt++;
- # move and shrink the wheel
- $self->_clipAndTranslate($self->{shrinkrate}, $x, $y);
- # process the animation using the 'after' Tk defering method
- $widget->after($self->{afterdelay}, sub {$self->_close($x, $y, $cnt)});
-
-&main::wincomment("READY");
-}
-
-# Generate hand rotation animation.
-sub _rotatewheel {
- my ($self, $angle, $cnt) = @_;
- my $widget = $self->{widget};
- my $group = $self->{topgroup};
-
-#grab position of widget
-my @pos = $widget->coords($group);
-my $x = ($pos[0]);
-my $y = ($pos[1]);
-
- $self->{turning} = 1;
- # first step of animation
- if (not $cnt) {
- $angle /= $self->{stepsnumber};
-
- # last step
- } elsif ($cnt == $self->{stepsnumber}) {
- if ($self->{fortune}) {
- $self->_fortune;
- } else {
- $self->{turning} = undef;
- }
-
- &main::displaywin();
- return;
- }
- $cnt++;
- # use 'rotation' Zinc method.
-
- $widget->rotate($self->{topgroup}, $angle);
-# process the animation using the 'after' Tk defering method
-
-#needed to keep wheel stationary while rotating
-$widget->coords($self->{topgroup},[$x,$y]);
-
- $widget->after($self->{afterdelay}, sub {$self->_rotatewheel($angle, $cnt)});
-
-}
-
-# Generate growing animation to notify jackpot
-sub _fortune {
- my ($self, $cnt) = @_;
- $cnt = 0 unless $cnt;
- my $zf;
- my $widget = $self->{widget};
- my $group = $self->{topgroup};
- my @pos = $widget->coords($group);
- # last step of animation
- if ($cnt == 6) {
- $self->{fortune} = undef;
- $self->{turning} = undef;
- return;
- # event steps : wheel grows
- } elsif ($cnt == 0 or $cnt % 2 == 0) {
- $zf = $self->{zoomrate};
- # odd steps : wheel is shrunk
- } else {
- $zf = 1/$self->{zoomrate};
- }
- $cnt++;
-
- # Now, we apply scale transformation to the Group item, using the 'scale'
- # Zinc method. Note that we reset group coords before scaling it, in order
- # that the origin of the transformation corresponds to the center of the
- # wheel. When scale is done, we restore previous coords of group.
- $widget->coords($group, [0, 0]);
- $widget->scale($group, $zf, $zf);
- $widget->coords($group, \@pos);
-
- # process the animation using the 'after' Tk defering method
- $widget->after(100, sub {print "\007";$self->_fortune($cnt)});
- &main::displaywin();
-}
-
-
-# Update group clipping and translation, using 'scale' and 'translate'
-# Zinc methods.
-sub _clipAndTranslate {
- my ($self, $shrinkfactor, $x, $y) = @_;
- $x = 0 unless $x;
- $y = 0 unless $y;
- $self->{widget}->scale($self->{itemclip}, $shrinkfactor, $shrinkfactor);
- if ($Tk::Zinc::VERSION lt "3.297") {
- $self->{widget}->translate($self->{topgroup}, $x, $y);
- } else {
- my ($xc, $yc) = $self->{widget}->coords($self->{topgroup});
- $self->{widget}->coords($self->{topgroup}, [$xc + $x, $yc + $y]);
- }
-}
-1;
diff --git a/Perl/demos/Tk/demos/zinc_data/background_texture.gif b/Perl/demos/Tk/demos/zinc_data/background_texture.gif
deleted file mode 100644
index 9bb4c11..0000000
--- a/Perl/demos/Tk/demos/zinc_data/background_texture.gif
+++ /dev/null
Binary files differ
diff --git a/Perl/demos/Tk/demos/zinc_data/hegias_parouest_TE.vid b/Perl/demos/Tk/demos/zinc_data/hegias_parouest_TE.vid
deleted file mode 100644
index 1755d80..0000000
--- a/Perl/demos/Tk/demos/zinc_data/hegias_parouest_TE.vid
+++ /dev/null
Binary files differ
diff --git a/Perl/demos/Tk/demos/zinc_data/paper-grey.gif b/Perl/demos/Tk/demos/zinc_data/paper-grey.gif
deleted file mode 100644
index 96775b5..0000000
--- a/Perl/demos/Tk/demos/zinc_data/paper-grey.gif
+++ /dev/null
Binary files differ
diff --git a/Perl/demos/Tk/demos/zinc_data/paper-grey1.gif b/Perl/demos/Tk/demos/zinc_data/paper-grey1.gif
deleted file mode 100644
index fe8c8ef..0000000
--- a/Perl/demos/Tk/demos/zinc_data/paper-grey1.gif
+++ /dev/null
Binary files differ
diff --git a/Perl/demos/Tk/demos/zinc_data/paper.gif b/Perl/demos/Tk/demos/zinc_data/paper.gif
deleted file mode 100644
index 3247d35..0000000
--- a/Perl/demos/Tk/demos/zinc_data/paper.gif
+++ /dev/null
Binary files differ
diff --git a/Perl/demos/Tk/demos/zinc_data/stripped_texture.gif b/Perl/demos/Tk/demos/zinc_data/stripped_texture.gif
deleted file mode 100644
index a0b842e..0000000
--- a/Perl/demos/Tk/demos/zinc_data/stripped_texture.gif
+++ /dev/null
Binary files differ
diff --git a/Perl/demos/Tk/demos/zinc_data/videomap_orly b/Perl/demos/Tk/demos/zinc_data/videomap_orly
deleted file mode 100644
index 17f9c66..0000000
--- a/Perl/demos/Tk/demos/zinc_data/videomap_orly
+++ /dev/null
Binary files differ
diff --git a/Perl/demos/Tk/demos/zinc_data/videomap_paris-w_90_2 b/Perl/demos/Tk/demos/zinc_data/videomap_paris-w_90_2
deleted file mode 100644
index fb32a5b..0000000
--- a/Perl/demos/Tk/demos/zinc_data/videomap_paris-w_90_2
+++ /dev/null
Binary files differ
diff --git a/Perl/demos/Tk/demos/zinc_data/zinc.gif b/Perl/demos/Tk/demos/zinc_data/zinc.gif
deleted file mode 100644
index b7eac16..0000000
--- a/Perl/demos/Tk/demos/zinc_data/zinc.gif
+++ /dev/null
Binary files differ
diff --git a/Perl/demos/Tk/demos/zinc_data/zinc_anti.gif b/Perl/demos/Tk/demos/zinc_data/zinc_anti.gif
deleted file mode 100644
index 4d1cda9..0000000
--- a/Perl/demos/Tk/demos/zinc_data/zinc_anti.gif
+++ /dev/null
Binary files differ
diff --git a/Perl/demos/Tk/demos/zinc_lib/MagicLens.pl b/Perl/demos/Tk/demos/zinc_lib/MagicLens.pl
deleted file mode 100644
index a625254..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/MagicLens.pl
+++ /dev/null
@@ -1,325 +0,0 @@
-#!/usr/bin/perl
-#-----------------------------------------------------------------------------------
-#
-# MagicLens.pl
-#
-# This small demo is based on Zinc::Graphics.pm for creating
-# the graphic items.
-# The magnifyer effect is obtained with the help of clipping,
-# and some glass effect is based on color transparency through
-# a triangles item bordering the magnifier
-#
-# Authors: Jean-Luc Vinot <vinot@cena.fr>
-#
-# $Id$
-#-----------------------------------------------------------------------------------
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-use Tk::Zinc;
-use Tk::Zinc::Graphics;
-use Getopt::Long;
-use strict 'vars';
-
-# the original fonts are not available everywhere, even if they are free!
-my $font_9b = '7x13bold'; # '-cenapii-bleriot mini-bold-r-normal--9-90-75-75-p-*-iso8859-15';
-my $font_8 = '7x13'; #'-cenapii-bleriot mini-book-r-normal--8-80-75-75-p-*-iso8859-15';
-my ($dx, $dy);
-
-my @basiccolors = (['Jaune','#fff52a','#f1f1f1','#6a6611'],
- ["Jaune\nOrangé",'#ffc017','#cfcfcf','#6b510a'],
- ['Orangé','#ff7500','#a5a5a5','#622d00'],
- ['Rouge','#ff2501','#8b8b8b','#620e00'],
- ['Magenta','#ec145d','#828282','#600826'],
- ["Violet\nRouge",'#a41496','#636363','#020940'],
- ["Violet\nBleu",'#6a25b6','#555555','#2a0f48'],
- ['Bleu','#324bde','#646464','#101846'],
- ['Cyan','#0a74f0','#818181','#064a9a'],
- ["Bleu\nVert",'#009bb4','#969696','#006474'],
- ['Vert','#0fa706','#979797','#096604'],
- ["Jaune\nVert",'#9dd625','#c9c9c9','#496311']);
-
-my $circle_coords = [[0,-30],[-16.569,-30,'c'],[-30,-16.569,'c'],[-30,0],[-30,16.569,'c'],[-16.569,30,'c'],[0,30],
- [16.569,30,'c'],[30,16.569,'c'],[30,0],[30,-16.569,'c'],[16.569,-30,'c'],[0,-30]];
-
-
-# MagicLens
-my %lensitems = ('back' => {-itemtype => 'arc',
- -coords => [[-100, -100],[100,100]],
- -params => {-priority => 10,
- -closed => 1,
- -filled => 1,
- -visible => 0,
- -tags => ['lensback'],
- },
- },
- 'light' => {-itemtype => 'pathline',
- -metacoords => {-type => 'polygone',
- -coords => [0, 0],
- -numsides => 36,
- -radius => 100,
- -startangle => 240,
- },
- -linewidth => 10,
- -shifting => 'in',
- -closed => 1,
- -graduate => {-type => 'double',
- -colors => [['#ffffff;0', '#6666cc;0', '#ffffff;0'],
- ['#ffffff;100', '#333399;50', '#ffffff;100']],
- },
- -params => {-priority => 50,
- },
- },
- 'bord' => {-itemtype => 'hippodrome',
- -coords => [[-100, -100],[100, 100]],
- -params => {-priority => 100,
- -closed => 1,
- -filled => 0,
- -linewidth => 2,
- -linecolor => '#222266;80'
- },
-
- },
- );
-
-
-# creation de la fenetre principale
-my $mw = MainWindow->new();
-$mw->geometry("1000x900+0+0");
-$mw->title('Color Magic Lens');
-
-
-# creation du widget Zinc
-my $zinc = $mw->Zinc(-render => 1,
- -width => 1000,
- -height => 900,
- -borderwidth => 0,
- -lightangle => 140,
- -borderwidth => 0,
- );
-$zinc->pack(-fill => 'both', -expand => 1);
-
-my $texture = $zinc->Photo(-file => Tk->findINC('demos/zinc_data/paper-grey1.gif'));
-$zinc->configure(-tile => $texture);
-
-# création des 2 vues
-my $normview = $zinc->add('group', 1, -priority => 100);
-my $lensview = $zinc->add('group', 1, -priority => 200);
-my $infoview = $zinc->add('group', $lensview);
-
-my $zoom=1.20;
-$zinc->scale($infoview, $zoom, $zoom);
-
-my $lenstexture = $zinc->Photo(-file => Tk->findINC('demos/zinc_data/paper-grey.gif'));
-$zinc->add('rectangle', $infoview,
- [[0,0],[1000,900]],
- -filled => 1,
- -fillcolor => '#000000',
- -tile => $lenstexture,
- -linewidth => 0,
- );
-
-my $gradbar;
-
-my $x = 60;
-for (my $i = 0; $i < 12; $i++) {
-
- # ajout d'un groupe dans chacune des les 2 vues
- my $cgroup = $zinc->add('group', $normview);
- $zinc->coords($cgroup, [$x, 60]);
- my $lgroup = $zinc->add('group', $infoview);
- $zinc->coords($lgroup, [$x, 60]);
-
- # références de la couleur : name, Zncolor saturée, ZnColor désaturée, ZnColor d'ombrage
- my ($colorname, $saturcolor, $greycolor, $shadcolor) = @{$basiccolors[$i]};
-
- # échantillon référence couleur saturée + relief
- my $refgrad = "=radial -12 -20|#ffffff 0|".$saturcolor." 40|".$shadcolor." 100";
- my $refitem = $zinc->add('curve', $cgroup,
- $circle_coords,
- -filled => 1,
- -fillcolor => $refgrad,
- -linewidth => 2,
- -priority => 100
- );
-
- # clone dans le group infoview
- my $clone = $zinc->clone($refitem);
- $zinc->chggroup($clone, $lgroup);
-
- # label couleur (infoview)
- $zinc->add('text', $lgroup,
- -priority => 200,
- -position => [0, 0],
- -text => $colorname,
- -anchor => 'center',
- -alignment => 'center',
- -font => $font_9b,
- -spacing => 2,
- );
-
- # dégradé de la couleur vers le gris de même luminosité
- my $bargrad = "=axial 270|".$saturcolor."|".$greycolor;
-
- # création des échantillons de couleur (curve multi-contours)
- $gradbar = $zinc->add('curve', $cgroup,
- [],
- -closed => 1,
- -filled => 1,
- -fillcolor => $bargrad,
- -linewidth => 2,
- -priority => 20,
- -fillrule => 'nonzero'
- );
-
- # définition des couleurs du dégradé (saturation 100% -> 0%)
- my $zncolors = &createGraduate($zinc, 11, [$saturcolor, $greycolor]);
- # on retire les valeurs alphas
- foreach (@{$zncolors}){ ($_) = split /;/, $_;}
-
- # réalisation des pas de dégradé (saturation -> désaturation)
- my $c;
- for ($c = 0; $c < 11; $c++) {
-
- # couleur du pas
- my $color = $zncolors->[$c];
-
- # item zinc de l'exemple couleur
- my $sample = $zinc->clone($refitem, -fillcolor => $color);
- $zinc->translate($sample, 0, 65*($c+1));
-
- # ajout à la curve multi-contours
- $zinc->contour($gradbar, 'add', 1, $sample);
-
- # déplacement vers le groupe info
- $zinc->chggroup($sample, $lgroup);
-
- # label texte (% saturation + ZnColor)
- my $txtcolor = ((10 - $c)*10)."%\n$color";
- $zinc->add('text', $lgroup,
- -priority => 200,
- -position => [0, ($c + 1)* 65],
- -text => $txtcolor,
- -anchor => 'center',
- -alignment => 'center',
- -font => $font_8,
- -spacing => 2,
- );
- }
-
-
- $x += 80;
-}
-
-# création de la MagicLens
-my $lensgroup = $zinc->add('group', 1,
- -priority => 300,
- -atomic => 1,
- -tags => ['lens'],
- );
-$zinc->coords($lensgroup, [300, 110]);
-&lensMove(0,0);
-
-# items graphiques
-while (my ($name, $style) = each(%lensitems)) {
- &buildZincItem($zinc, $lensgroup, %{$style});
-}
-
-# clipping lensview
-my $lenszone = $zinc->clone('lensback', -tags => ['lenszone']);
-$zinc->chggroup($lenszone, $lensview, 1);
-$zinc->itemconfigure($lensview, -clip => $lenszone);
-
-# consigne globale
-my $consigne = $zinc->add('text', 1,
- -position => [30, 840],
- -text => "<Up>, <Down>, <Left> and <Right> keys or <Mouse Drag>\nMove the Magic Color Lens behind the color gradiants\nto see the ZnColor value of Hue/saturation\n",
- -font => $font_8,
- -alignment => 'left',
- -color => '#ffffff',
- -spacing => 2,
- );
-
-my $cclone = $zinc->clone($consigne, -font => $font_9b);
-$zinc->chggroup($cclone, $infoview);
-
-&setBindings;
-
-
-MainLoop;
-#----------------------------------------------------------------------- fin de MAIN
-
-
-sub setBindings {
- $zinc->bind('lens', '<1>', sub {&lensStart();});
- $zinc->bind('lens', '<B1-Motion>', sub {&lensMove();});
- $zinc->bind('lens', '<ButtonRelease>', sub {&lensStop();});
-
- $mw->Tk::focus();
-
- # Up, Down, Right, Left : Translate
- $mw->Tk::bind('<KeyPress-Up>', sub {lensTranslate('up');});
- $mw->Tk::bind('<KeyPress-Down>', sub {lensTranslate('down');});
- $mw->Tk::bind('<KeyPress-Left>', sub {lensTranslate('left');});
- $mw->Tk::bind('<KeyPress-Right>', sub {lensTranslate('right');});
-}
-
-
-
-
-#-----------------------------------------------------------------------------------
-# Callback CATCH de sélection (début de déplacement) de la lentille
-#-----------------------------------------------------------------------------------
-sub lensStart {
- my $ev = $zinc->XEvent;
- ($dx, $dy) = (0 - $ev->x, 0 - $ev->y);
-
-}
-
-
-#-----------------------------------------------------------------------------------
-# Callback MOVE de déplacement de la lentille
-#-----------------------------------------------------------------------------------
-sub lensMove {
- my ($tx, $ty) = @_;
-
- if (defined $tx and defined $ty) {
- # interaction clavier
- $zinc->translate('lens', $tx, $ty);
- $zinc->translate('lenszone', $tx, $ty);
-
- } else {
- my $ev = $zinc->XEvent;
- $zinc->translate('current', $ev->x + $dx, $ev->y +$dy);
- $zinc->translate('lenszone', $ev->x + $dx, $ev->y +$dy);
- ($dx, $dy) = (0 - $ev->x, 0 - $ev->y);
- }
-
- my ($lx, $ly) = $zinc->coords('lens');
- $zinc->coords($infoview, [$lx * (1-$zoom), $ly * (1-$zoom)]);
-
-}
-
-
-#-----------------------------------------------------------------------------------
-# Callback RELEASE de relaché (fin de déplacement) de la lentille
-#-----------------------------------------------------------------------------------
-sub lensStop {
- &lensMove;
-}
-
-sub lensTranslate {
- my $way = shift;
-
- my $dx = ($way eq 'left') ? -10 : ($way eq 'right') ? 10 : 0;
- my $dy = ($way eq 'up') ? -10 : ($way eq 'down') ? 10 : 0;
-
- &lensMove($dx, $dy);
-
-}
-
-
-
-1;
diff --git a/Perl/demos/Tk/demos/zinc_lib/Zetris.pl b/Perl/demos/Tk/demos/zinc_lib/Zetris.pl
deleted file mode 100644
index f6c9df0..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/Zetris.pl
+++ /dev/null
@@ -1,972 +0,0 @@
-#!/usr/bin/perl
-# Zinc port of TkTetris from Slaven Rezic
-#------------------------------------------------------------------------------
-#
-# Zetris - A Zinc Toy-Appli based on cool TkTetris from Slaven Rezic
-#
-# $Id$
-#
-# Copyright (C) 2002 Centre d'Etudes de la Navigation Aérienne
-# Author: Marcellin Buisson <buisson@cena.fr>
-#
-# Hacked from Original Code to adapt to Tk::Zinc Widget :
-#
-#------------------------------------------------------------------------------
-#
-# Author: Slaven Rezic
-#
-# Copyright (C) 1997, 1999, 2000, 2002 Slaven Rezic. All rights reserved.
-# This program is free software; you can redistribute it and/or
-# modify it under the same terms as Perl itself.
-#
-# Mail: slaven.rezic@berlin.de
-# WWW: http://www.rezic.de/eserte/
-#
-#------------------------------------------------------------------------------
-
-#------------------------------------------------------------------------------
-# What are the differences with the original TkTetris ?
-#------------------------------------------------------------------------------
-#
-# - This TkTetris-like uses a tk widget similar to the canvas
-# and called "Zinc". Zinc bring to Tk widgets openGL features
-# like transparency, color gradients, scaling.
-# So to use Zetris graphic enhancement, you need openGL capability.
-# Zinc comes with other features like grouping and clipping.
-#
-# - A color gradient is used for Zetris background,
-#
-# - Zetris balls are filled with transparently color gradients,
-# (transparency is visible when balls fall over TkZinc logo)
-#
-# - Zetris balls have a little transparent shadow,
-#
-# - The TkZinc logo is animated by rotation and scaling effects,
-#
-# - Introducing of groups provided by Zinc for grouping items
-# This feature is particularly useful for applying transformations,
-#
-# - The TkZinc logo over background isn't an image but only curves
-# and color gradients (made by <vinot@cena.fr>)
-#
-# - Please feel free to provide any feedback to <buisson@cena.fr>
-#
-# - CM: Zetris now works even without openGL. It is just ugly!
-#
-#------------------------------------------------------------------------------
-
-#------------------------------------------------------------------------------
-# ToDos :
-#
-# - Complete this basic version in a full playable game like tktetris.
-# - Review conception through Zinc features.
-# (using groups capabilities for drawing blocks for instance)
-# - Adding special effects when completing a line or changing level.
-#
-#------------------------------------------------------------------------------
-use Tk;
-use Tk::Zinc;
-use strict;
-use Tk::Zinc::Logo;
-
-package main;
-
-use Getopt::Long;
-
-use vars qw($VERSION);
-
-$VERSION = sprintf("%d.%00d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-my $max_size = 4;
-my $nmbr_blks = 7;
-my $width = 12;
-my $height = 20;
-my $geometry;
-
-my $level;
-my $just_started = 1;
-my $speed;
-my $base_speed = 500;
-
-my $last_resize;
-my $fontheight = 0;
-
-my $basefont
- = sub { sprintf "-*-helvetica-medium-r-normal--%s-*", $_[0] };
-my $base2font
- = sub { sprintf "-*-courier-medium-r-normal--%s-*", $_[0] };
-
-my $blocks = 0;
-my $lines = 0;
-my $mylines = 0;
-
-my $pause = undef;
-my $pause_w;
-my $freefall = 0;
-my $points = 0;
-my $flat = 0;
-my $moveable_drop = 0;
-
-my $old_win_height;
-my $draw_shadow = 1;
-
-# Animation constants
-my $afterdelay = 1;
-my $stepsnumber = 10;
-my $zoomrate = 1.1;
-
-my $active_block = undef;
-my $active_block_nr = undef;
-my $active_dir = undef;
-my $next_block = undef;
-my $next_block_nr = undef;
-my $next_dir = undef;
-my $posx = undef;
-my $posy = undef;
-
-my $n = 0;
-
-my(%color_dark, %color_very_dark);
-my %color_bright =
- (2 => 'red',
- 3 => 'green',
- 4 => 'blue',
- 5 => 'cyan',
- 6 => 'yellow',
- 7 => 'orange',
- 8 => 'pink',
- );
-
-# Blocks matrix
-my $block =
- [[[qw(0 0 0 0)],
- [qw(0 2 0 0)],
- [qw(0 2 2 0)],
- [qw(0 2 0 0)]],
- [[qw(0 0 0 0)],
- [qw(3 3 0 0)],
- [qw(0 3 0 0)],
- [qw(0 3 0 0)]],
- [[qw(0 0 0 0)],
- [qw(0 4 4 0)],
- [qw(0 4 0 0)],
- [qw(0 4 0 0)]],
- [[qw(0 0 0 0)],
- [qw(0 5 0 0)],
- [qw(0 5 5 0)],
- [qw(0 0 5 0)]],
- [[qw(0 0 0 0)],
- [qw(0 6 0 0)],
- [qw(6 6 0 0)],
- [qw(6 0 0 0)]],
- [[qw(0 7 0 0)],
- [qw(0 7 0 0)],
- [qw(0 7 0 0)],
- [qw(0 7 0 0)]],
- [[qw(0 0 0 0)],
- [qw(0 0 0 0)],
- [qw(8 8 0 0)],
- [qw(8 8 0 0)]],
- ];
-
-my $playfield;
-reset_playfield();
-
-my $step_x = 20;
-my $step_y = 20;
-my $boxsize_x = $step_x-2;
-my $boxsize_y = $step_y-2;
-my $block_border = int($boxsize_x/10);
-my $help_top;
-
-my $top = MainWindow->new();
-$top->minsize(181, 83);
-$top->title('Zetris');
-
-{
- my $width_height_set = 0;
- if ($geometry)
- {
- if ($geometry =~ /^(=?(\d+)x(\d+))?(([+-]\d+)([+-]\d+))?$/)
- {
- if (defined $2 and defined $3)
- {
- my($width, $height) = ($2, $3);
- $top->GeometryRequest($width, $height);
- $width_height_set++;
- }
- if (defined $5 and defined $6)
- {
- my($x, $y) = ($5, $6);
- $top->geometry("$x$y");
- }
- }
- else
- {
- die "Can't parse geometry: $geometry";
- }
- }
- if (!$width_height_set)
- {
- $top->GeometryRequest($top->screenwidth,
- $top->screenheight);
- }
-}
-
-my $base_level = 1;
-
-$level = level();
-$speed = speed();
-
-resize_calc();
-
-while(my($k, $v) = each %color_bright)
- {
- $color_dark{$k} = $top->Darken($v, 80);
- $color_very_dark{$k} = $top->Darken($v, 60);
- }
-
-
-# Zinc Widget (openGl rendering option set to 1)
-my $tetris = $top->Zinc(-width => $step_x*($width-2),
- -height => $step_y*($height-1),
- -backcolor => '#707070',
- -lightangle => 130,
- -render => 1,
- )->pack;
-
-# Zetris will no more die if there is no openGL render. I did some minor
-# modification (transparency, item priority) to make all needed item
-# visible, even without alpha-transparency
-
-my $render = $tetris->cget(-render);
-
-my $shadow_group = $tetris->add('group',1, -visible => 1);
-
-my $pause_group = $tetris->add('group',1, -visible => 1);
-
-my $topgroup = 1;
-
-$tetris->pack(-fill => 'both',
- -expand=> 1);
-
-$tetris->add('rectangle',
- 1, # Zinc group
- [0, 0,$step_x*($width-2) ,$step_y*($height-1)] ,
- -filled => 1,
- -linewidth => 0,
- -fillcolor => $render ? "=axial 90 |black;40|gray80;60" : "grey80",
- -visible => 1);
-
-my $group = $tetris->add('group', 1, );
-my $logo = Tk::Zinc::Logo->new(-widget => $tetris,
- -parent => $group,
- -position => [$step_x*($width-2)/2-200,
- $step_y*($height-1)/2],
- );
-
-$tetris->lower($group) if $render;
-
-my $score_group = $tetris->add('group',1, -visible => 1);
-my $new = $tetris->add('text',$score_group,
- -text => " $lines Line\n",
- #-anchor => 'e',
- -font => $basefont->($fontheight),
- -position => [$width-2,10],
- );
-$tetris->add('text',$score_group,
- -text => "Sorry, without openGL,\nZtetris is just ugly.",
- #-anchor => 'e',
- -font => $basefont->($fontheight),
- -position => [$width-2,100],
- ) if !$render;
-
-$tetris->lower($score_group) if $render;
-
-my $timer = $top->after(speed(), sub {
- $old_win_height = $top->height;
- $just_started = 0;
- action();
- });
-
-make_key_bindings($top);
-
-print "\n***********************************************\n\n For help on the game toggle pause with 'p'\n\n***********************************************\n\n";
-
-MainLoop;
-
-#------------------------------------------------------------------------
-sub reset_playfield
- {
- my $i;
- # $fake_height: mit negativen Indices können die n-letzten Elemente
- # angesprochen werden...
- my $fake_height = $height+$max_size+1;
- for $i (0 .. $fake_height-1)
- {
- $playfield->[$i][0] = 1;
- my $j;
- for $j (1 .. $width-2)
- {
- $playfield->[$i][$j] = 0;
- }
- $playfield->[$i][$width-1] = 1;
- }
- for $i (0 .. $width-1)
- {
- $playfield->[$height-1][$i] = 1;
- }
- }
-
-sub speed
- {
- my $speed = $base_speed - ($base_speed*$level)/20;
- if ($speed <= 5) { $speed = 5 }
- $speed;
- }
-
-sub level
- {
- int($lines / 10) + 1 + $base_level
- }
-
-sub resize_calc
- {
- $last_resize = time();
- my $win_height;
- if ($just_started)
- {
- $win_height = $top->reqheight;
- }
- else
- {
- $win_height = $top->height;
- }
- $step_x = $step_y = int($win_height/($height+3));
- my $gap = ($step_x > 10 ? 2 : 1);
- $boxsize_x = $step_x-$gap;
- $boxsize_y = $step_y-$gap;
- $block_border = int($boxsize_x/10);
- if ($block_border < 1) { $block_border = 1 }
- my @font_height = (10, 11, 12, 14, 17, 18, 20, 24, 25, 34);
- my $req_fontheight = $win_height/30;
- $fontheight = 0;
- foreach (@font_height)
- {
- if ($_ > $req_fontheight)
- {
- $fontheight = $_;
- last;
- }
- }
- if (!$fontheight) { $fontheight = $font_height[$#font_height] }
- # the following line has been commented out since
- # it modify default font for every application
- # launched by zinc-demos! CM 26/3/02
- # $top->optionAdd("*font" => $basefont->($fontheight));
- }
-
-sub make_key_bindings
- {
- my $top = shift;
-# $top->bind('<Escape>' => \&quit_game);
-# $top->bind('<q>' => \&quit_game);
-# $top->bind('<Control-c>' => \&quit_game);
- $top->bind('<Left>' => sub { move('left') });
- $top->bind('<Right>' => sub { move('right') });
- $top->bind('<Up>' => sub { move('antiturn') });
- $top->bind('<Down>' => sub { move('turn') });
- $top->bind('<j>' => sub { move('left') });
- $top->bind('<l>' => sub { move('right') });
- $top->bind('<k>' => sub { move('turn') });
- foreach (qw/space KP_Enter/) {
- $top->bind("<$_>" => sub { move('freefall') });
- }
- $top->bind('<p>' => sub { toggle_pause() });
- $top->bind('<n>' => \&stop_and_new_game);
- $top->bind('<h>' => \&help);
- #$top->bind('all', '<F1>' => \&help); # don't pause
- $top->bind('all', '<F2>' => \&lost);
- #XXX Leave und Enter herausnehmen
- $top->bind('<FocusOut>' => sub { inc_pause(1) });
- # $top->bind('<Leave>' => sub { inc_pause(1) });
- $top->bind('<FocusIn>' => sub { dec_pause(1) });
- #$top->bind('<ButtonRelease>' => sub { toggle_pause()});
- #$top->bind('<Key-space>' => sub { toggle_pause()});
- # $top->bind('<Enter>' => sub { dec_pause(1) });
- }
-
-
-sub inc_pause
- {
- my $quiet = shift;
- $pause++;
- if (!$quiet && !Tk::Exists($pause_w))
- {
- my $width = $top->width;
- my $height = $top->height;
- $pause_w = $tetris->add('text',$pause_group,
- -text => "PAUSE MODE :\n Type p to continue\n
-\n\n\nHELP : \n\n- 'p' toggle pause\n\n- Arrow keys to move blocks\n\n- 'n' to start a new game\n\n ",
- -font => $basefont->($fontheight),
- -position => [30,50],
- -anchor => 'nw',
-
- );
- }
-}
-
-sub dec_pause
- {
- if ($pause)
- {
- $pause--;
- if ($pause < 1)
- {
- $tetris->remove($pause_w);
- undef $pause;
- }
- }
- }
-
-sub toggle_pause
- {
- my $quiet = shift;
- if ($pause)
- {
- $tetris->remove($pause_w);# if Tk::Exists($pause_w);
- undef $pause;
- }
- else
- {
-
- inc_pause($quiet);
- }
- }
-
-
-sub action
- {
- if (!$pause)
- {
- if (!defined $active_block_nr)
- {
- if (!defined $next_block_nr)
- {
- get_next_block();
- }
- $active_block_nr = $next_block_nr;
- $blocks++;
- $active_block = [];
- copyblock($next_block, $active_block);
- $active_dir = $next_dir;
- get_next_block();
- }
- if (defined $posx)
- {
- # erstes Zeichnen
- if (testblock($active_block, $posx, $posy+1))
- {
- drawblock($posx, $posy, 0);
- $posy++;
- drawblock($posx, $posy, 1);
- }
- else
- {
- array_update(($level+1) * int(($height-$posy+5)/5),
- $posx, $posy);
- return;
- }
- }
- else
- {
- $posx = int($width / 2) - 1;
- $posy = -$max_size;
- }
- }
- $timer = $top->after($freefall ? 1 : speed(), \&action);
- }
-
-sub get_next_block
- {
- $next_block_nr = int(rand()*$nmbr_blks);
- $next_dir = int(rand()*4);
- $next_block = $block->[$next_block_nr];
- for (0 .. $next_dir)
- {
- turn($next_block_nr, $next_block);
- }
- }
-
-sub turn
- {
- my($number, $block) = @_;
- my($i, $j, $help_block);
- if ($number != 6)
- {
- if ($number < 5)
- {
- for $i (1 .. $max_size-1)
- {
- for $j (0 .. $max_size-2)
- {
- $help_block->[$max_size-1-$j][$i-1] = $block->[$i][$j];
- }
- }
- for $i (1 .. $max_size-1)
- {
- for $j (0 .. $max_size-2)
- {
- $block->[$i][$j] = $help_block->[$i][$j];
- }
- }
- }
- else
- {
- for $i (0 .. $max_size-1)
- {
- for $j (0 .. $max_size-1)
- {
- $help_block->[$max_size-1-$j][$i] = $block->[$i][$j];
- }
- }
- copyblock($help_block, $block);
- }
- }
- }
-
-sub copyblock
- {
- my($from, $to) = @_;
- die if ref $from ne 'ARRAY' || ref $to ne 'ARRAY';
- my($i, $j);
- for $i (0 .. $max_size-1)
- {
- for $j (0 .. $max_size-1)
- {
- $to->[$i][$j] = $from->[$i][$j];
- }
- }
- }
-sub rectangle
- {
- my($x, $y, $mode, $zinc) = @_;
- $zinc->remove("$x-$y"); # Zinc command for deleting items
- $zinc->remove("ombre$x-$y");
- if ($mode)
- {
- my($xx, $yy);
- ($xx, $yy) = (($x-1)*$step_x, $y*$step_y);
- my $color = $color_bright{$mode};
- # Adding new Zinc item : ball shadow
- my $ombre=$zinc->add(
- 'arc',$shadow_group,[$xx+10,$yy+10,$xx+$boxsize_x+10,$yy+$boxsize_y+10],
- -visible=>1,
- -filled=>1,
- -fillcolor => $render ? "=path 50 50 |black;100 0|black;80 20|black;0 100" : "grey90", # color gradiant
- -linewidth => 0,
- -linecolor => 'yellow',
- -priority => $render ? 6 : 10,
- -tags => ["ombre$x-$y"]);
-
- $zinc->itemconfigure($shadow_group, -priority => 2);
-
- # Adding new Zinc item : ball
- my $cercle=$zinc->add(
- 'arc',$topgroup,[$xx,$yy,$xx+$boxsize_x,$yy+$boxsize_y],
- -visible=>1,
- -filled=>1,
- -fillcolor => $render ? "=radial -20 -20 |white;90|$color;90" : $color,
- -linewidth => 1,
- -priority => 5,
- -linecolor => "$color;80",
- -tags => ["$x-$y"]);
- }
- }
-
-sub testblock
- {
- my($active_block, $posx, $posy) = @_;
- for(my $i = 0; $i <= $max_size-1; $i++)
- {
- for(my $j = 0; $j <= $max_size-1; $j++)
- {
- if ($active_block->[$i][$j])
- {
- if ($playfield->[$posy+$i][$posx+$j])
- {
- return 0;
- }
- }
- }
- }
- 1;
- }
-
-sub drawblock
- {
- my($posx, $posy, $mode, $zinc) = @_;
- my $y = $posy;
- $zinc = $tetris if !$zinc;
- for(my $i = 0; $i <= $max_size-1; $i++)
- {
- my $x = $posx;
- for(my $j = 0; $j <= $max_size-1; $j++)
- {
- if ($active_block->[$i][$j])
- {
- if (!$mode)
- {
- rectangle($x, $y, 0, $zinc);
- }
- else
- {
- rectangle($x, $y, $active_block->[$i][$j], $zinc);
- }
- }
- $x++;
- }
- $y++;
- }
- }
-
-
-
-sub new_game {
- reset_playfield();
- renew_field();
- reset_block();
- $next_block_nr = undef;
- reset_game_param();
- action();
-}
-
-sub stop_and_new_game {
- stop_game();
- new_game(),
- }
-
-## no more used, because it quits zinc-demos
-sub quit_game {
-
- print "Bye!\n";
- exit;
-}
-
-sub lost {
- $top->destroy;
- print "You lost :o( !\n";
- exit;
- }
-
-sub reset_game_param {
- $points = $blocks = $lines = 0;
- $level = level();
- $speed = speed();
- $pause = undef;
-}
-
-sub stop_game {
- undef_timer();
- undef $active_block;
-}
-
-sub delete_line
- {
- my($y) = @_;
- my $yy = $y*$step_y;
- my $x;
- for $x (1 .. $width-2)
- {
- my $xx = ($x-1)*$step_x;
- $tetris->add
- ('rectangle',1,
- [$xx, $yy, $xx+$boxsize_x, $yy+$boxsize_y],
- -filled => 1,
- -fillcolor => 'orange;50',
- -tags => ['delline'],
- );
- }
- $tetris->idletasks;
- short_sleep(0.05);
- $tetris->remove('delline');
- my $deuxpi = 3.1416;
- my $i = 1;
- my $angle = 360;
- # special effect on TkZinc logo
- rotation($deuxpi*$angle/360);
- $mylines++;
- $tetris->itemconfigure($new,-text => " $mylines Lines\n", -font => $basefont->($fontheight));
- }
-
-sub rotation
- {
- my ($angle, $cnt) = @_;
- # first step of animation
- if ($cnt == $stepsnumber)
- {
- inflation(); # scaling effect
- return;
- }
- $cnt++;
- # use 'rotation' Zinc method.
- my $stepi = 360/$stepsnumber;
- $angle = $stepi*2*3.1416/360;
- $tetris->rotate($group, $angle, 250, 450 );
- # process the animation using the 'after' Tk defering method
- $tetris->after($afterdelay, sub {rotation($angle, $cnt)});
- }
-
-sub inflation
- {
- my ($cnt) = @_;
- my @pos = $tetris->coords($group);
- my $zf;
- # last step of animation
- if ($cnt == 6)
- {
- return;
- # event steps : wheel grows
- }
- elsif ($cnt % 2 == 0)
- {
- $zf = 4*$zoomrate;
- # odd steps : wheel is shrunk
- }
- else
- {
- $zf = 1/(4*$zoomrate);
- }
- $cnt++;
- # Now, we apply scale transformation to the Group item, using the 'scale'
- # Zinc method. Note that we reset group coords before scaling it, in order
- # that the origin of the transformation corresponds to the center of the
- # wheel. When scale is done, we restore previous coords of group.
- $tetris->coords($group, [0, 0]);
- $tetris->scale($group, $zf, $zf);
- $tetris->coords($group, \@pos);
- # process the animation using the 'after' Tk defering method
- $tetris->after(100, sub {inflation($cnt)});
- }
-
-sub game_over {
- stop_game();
- # insert_highscore();
- # show_highscore('Game over');
- # save_highscore();
- #toggle_pause();
- my $width = $top->width;
- my $height = $top->height;
- my $new = $tetris->add('text',$pause_group,
- -font => $basefont->($fontheight),
- -text => "You lost ! :o)\ntype 'n' to try again !",
- -position => [20,100],
- );
- $top->update('idletasks');
- short_sleep(1);
- $tetris->remove($new);
- }
-
-sub move {
- my($dir) = @_;
- if (!$active_block || !defined $posx || $pause) {
- $top->bell;
- return;
- }
- if ($dir eq 'right' and testblock($active_block, $posx+1, $posy)) {
- drawblock($posx, $posy, 0);
- $posx++;
- drawblock($posx, $posy, 1);
- } elsif ($dir eq 'left' and testblock($active_block, $posx-1, $posy)) {
- drawblock($posx, $posy, 0);
- $posx--;
- drawblock($posx, $posy, 1);
- } elsif ($dir eq 'turn') {
- my $help_block = [];
- copyblock($active_block, $help_block);
- turn($active_block_nr, $help_block);
- if (testblock($help_block, $posx, $posy)) {
- drawblock($posx, $posy, 0);
- copyblock($help_block, $active_block);
- drawblock($posx, $posy, 1);
- }
- } elsif ($dir eq 'antiturn') {
- my $help_block = [];
- copyblock($active_block, $help_block);
- anti_turn($active_block_nr, $help_block);
- if (testblock($help_block, $posx, $posy)) {
- drawblock($posx, $posy, 0);
- copyblock($help_block, $active_block);
- drawblock($posx, $posy, 1);
- }
- } elsif ($dir eq 'freefall') {
- if ($moveable_drop) {
- $freefall = 1;
- undef_timer();
- action();
- } else {
- my $free_fall = 0;
- while (testblock($active_block, $posx, $posy+1)) {
- drawblock($posx, $posy, 0);
- $posy++;
- $free_fall++;
- drawblock($posx, $posy, 1);
- $top->idletasks;
- }
- array_update(($level+1)*int(($free_fall+$height-$posy+5)/5),
- $posx, $posy);
- }
- }
- }
-
-sub array_update
- {
- my($plus, $posx, $posy) = @_;
- my($i, $j);
- undef_timer();
- delete_shadow();
- for $i (0 .. $max_size-1)
- {
- for $j (0 .. $max_size-1) {
- if ($active_block->[$i][$j] and $posy+$i >= 0) {
- $playfield->[$posy+$i][$posx+$j] = $active_block->[$i][$j];
- } else {
- if ($active_block->[$i][$j]) {
- game_over();
- return;
- }
- }
- }
- }
- $points += $plus;
-
- if ($posy >= 0) {
- for $i ($posy .. $height-2) {
- if (to_del_line($i)) {
- delete_line($i);
- $lines++;
- $points += 10*($level+1);
- for $j (reverse(0 .. $i-1)) {
- my $k;
- for $k (1 .. $width-2) {
- $playfield->[$j+1][$k] = $playfield->[$j][$k];
- }
- }
- renew_field($i);
- }
- }
- }
-
- my $oldlevel = $level;
- $level = level();
- if ($oldlevel != $level) {
- my $width = $top->width;
- my $height = $top->height;
- my $newlevel = $tetris->add('text',$pause_group,
- -text => 'NEW LEVEL',
- -font => $basefont->($fontheight),
- -position => [20,20],
- );
- $top->update('idletasks');
- short_sleep(0.5);
- $tetris->remove($newlevel);
- }
-
- reset_block();
- action();
-}
-
-sub anti_turn
- {
- my($number, $block) = @_;
- for (1 .. 3) { turn($number, $block) }
-}
-
-sub undef_timer {
- if ($timer) {
- $timer->cancel;
- undef $timer;
- }
-}
-
-sub delete_shadow {
- return if !$draw_shadow;
- for(my $x = 1; $x <= $width-1; $x++) {
-# rectangle($x, 0, 0, $shadow);
- }
-}
-
-sub to_del_line {
- my($posy) = @_;
- my $i;
-
- for $i (1 .. $width-2) {
- if ($posy >= 0 and !$playfield->[$posy][$i]) {
- return 0;
- }
- }
- 1;
-}
-sub reset_block {
- undef $active_block_nr;
- undef $posx;
- $freefall = 0;
-}
-
-sub short_sleep {
- my $sleep = shift;
- if ($^O =~ /win/i) {
- $top->Busy;
- my $wait = 0;
- $top->after($sleep*1000, sub { $wait = 1 });
- $top->waitVariable(\$wait);
- $top->Unbusy;
- } else {
- eval { select(undef, undef, undef, $sleep) };
- }
-}
-
-sub renew_field {
- my($max_y) = @_;
- $max_y = $height-2 if !defined $max_y;
- my($i, $j);
- for $i (0 .. $max_y) {
- for $j (1 .. $width-2) {
- if ($playfield->[$i][$j]) {
- rectangle($j, $i, $playfield->[$i][$j], $tetris);
- } else {
- rectangle($j, $i, 0, $tetris);
- }
- }
- }
-}
-
-sub help
- {
- inc_pause();
- if (defined $help_top and Tk::Exists($help_top))
- {
- $help_top->raise;
- return;
- }
- require Tk::ROText;
- my $firebutton = 'Button';
- eval { require Tk::FireButton; Tk::FireButton->VERSION(1.04); };
- $help_top = $top->Toplevel(-title => 'Tetris Help');
- make_key_bindings($help_top);
- my $ti = "Zetris help :\n - truc 1\n - truc 2\n - truc 3\n \n";
- my $create_but = sub {
- my($t, $command, $fire) = @_;
- my $button = ($fire ? $firebutton : 'Button');
- my $but = $tetris->add('text',$pause_group,
- -text => $ti,
- -font => $base2font->(12),
- -position => [20,20],
- );
- };
-
- my $cb = $help_top->Button(-text => 'Close',
- -font => $base2font->(12),
- -command => sub { $help_top->destroy })->pack;
- $help_top->bind('<Escape>' => sub { $cb->invoke });
-}
diff --git a/Perl/demos/Tk/demos/zinc_lib/all_options.pl b/Perl/demos/Tk/demos/zinc_lib/all_options.pl
deleted file mode 100644
index 25140f2..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/all_options.pl
+++ /dev/null
@@ -1,154 +0,0 @@
-#!/usr/bin/perl -w
-# $Id$
-# This simple demo has been developped by C. Mertz <mertz@cena.fr>
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-use Tk::Zinc;
-use Tk::Pane;
-
-use strict;
-
-my $mw = MainWindow->new();
-
-# The explanation displayed when running this demo
-my $label=$mw->Label(-text =>
-"Click on one of the following
-buttons to get a list of Item
-attributes (or zinc options)
-with their types.\n",
- -justify => 'left')->pack(-padx => 10, -pady => 10);
-
-
-# Creating the zinc widget
-my $zinc = $mw->Zinc(-width => 1, -height => 1,
- -font => "10x20", # usually fonts are sets in resources
- # but for this example it is set in the code!
- -borderwidth => 0, -relief => 'sunken',
- )->pack;
-
-# Creating an instance of every item type
-my %itemtypes;
-
-# These Items have fields! So the number of fields must be given at creation time
-foreach my $type qw(tabular track waypoint) {
- $itemtypes{$type} = $zinc->add($type, 1, 0);
-}
-
-# These items needs no specific initial values
-foreach my $type qw(group icon map reticle text window) {
- $itemtypes{$type} = $zinc->add($type, 1);
-}
-
-# These items needs some coordinates at creation time
-# However curves usually needs more than 2 points.
-foreach my $type qw(arc curve rectangle) {
- $itemtypes{$type} = $zinc->add($type, 1, [0,0 , 1,1]);
-}
-# Triangles item needs at least 3 points for the coordinates
-foreach my $type qw(triangles) {
- $itemtypes{$type} = $zinc->add($type, 1, [0,0 , 1,1 , 2,2]);
-}
-
-
-sub showAllOptions {
- my ($type) = @_;
-
- my $tl = $mw->Toplevel;
- my $title = "All options of an item $type";
- my @options;
- if ($type eq 'zinc') {
- @options = $zinc->configure();
- $title = "All options of zinc widget";
- }
- else {
- @options = $zinc->itemconfigure($itemtypes{$type});
- $title = "All attributes of an item $type";
- }
- $tl->title($title);
- my $frame = $tl->Scrolled('Pane',
- -scrollbars => 'e',
- -height => 600,
- );
- $frame->pack(-padx => 10, -pady => 10,
- -ipadx => 10,
- -fill => 'both',
- -expand => 1,
- );
-
- my $fm = $frame->LabFrame(-labelside => 'acrosstop',
- -label => $title,
- )->pack(-padx => 10, -pady => 10,
- -ipadx => 10,
- -fill => 'both');
- my $bgcolor = 'ivory';
- $fm->Label(-text => 'Option', -background => $bgcolor, -relief => 'ridge')
- ->grid(-row => 1, -column => 1, -ipady => 10, -ipadx => 5, -sticky => 'nswe');
- $fm->Label(-text => ($type eq 'zinc') ? 'optionClass' : 'Type',
- -background => $bgcolor, -relief => 'ridge')
- ->grid(-row => 1, -column => 2, -ipady => 10, -ipadx => 5, -sticky => 'nswe');
- $fm->Label(-text => ($type eq 'zinc') ? 'defaultValue' : 'ReadOnly',
- -background => $bgcolor, -relief => 'ridge')
- ->grid(-row => 1, -column => 3, -ipady => 10, -ipadx => 5, -sticky => 'nswe');
- my $i = 2;
- my %options; #we used this hastable to sort the options by their names
-
- if ($type eq 'zinc') {
- for my $elem (@options) {
-# print "$elem @$elem\n";
- my ($optionName, $optionDatabaseName, $optionClass, $default, $optionValue) = @$elem;
- $options{$optionName} = [$optionClass, $default, "", $optionValue];
- }
- }
- else {
- for my $elem (@options) {
- my ($optionName, $optionType, $readOnly, $empty, $optionValue) = @$elem;
- $options{$optionName} = [$optionType, $readOnly, $empty, $optionValue];
- }
- }
- for my $optionName (sort keys %options) {
- my ($optionType, $readOnly, $empty, $optionValue) = @{$options{$optionName}};
- $fm->Label(-text => $optionName, -relief => 'ridge')
- ->grid(-row => $i, -column => 1, -ipady => 10, -ipadx => 5, -sticky => 'nswe');
- $fm->Label(-text => $optionType, -relief => 'ridge')
- ->grid(-row => $i, -column => 2, -ipady => 10, -ipadx => 5, -sticky => 'nswe');
-
- # $empty is for provision by Zinc
- if ($type ne 'zinc') {
- if ($readOnly) {$readOnly = "read only"} else { $readOnly = "" }
- }
- $fm->Label(-text => $readOnly, -relief => 'ridge')
- ->grid(-row => $i, -column => 3, -ipady => 10, -ipadx => 5, -sticky => 'nswe');
- # we do not display $optionValue for these fake items
- $i++;
- }
- $tl->Button(-text => 'Close',
- -command => sub {$tl->destroy})->pack;
-
-}
-
-my $col = $mw->Frame()->pack();
-
-my $width=0;
-foreach my $type (sort keys %itemtypes) {
- if (length ($type) > $width) {
- $width = length ($type);
- }
-}
-
-foreach my $type (sort keys %itemtypes) {
- $col->Button(-text => "$type",
- -width => $width,
- -command => sub {&showAllOptions ($type);},
- )->pack(-pady => 4);
-}
-$col->Button(-text => "zinc widget options",
- -command => sub {&showAllOptions ('zinc');},
- )->pack(-pady => 4);
-
-MainLoop();
-
-
-1;
diff --git a/Perl/demos/Tk/demos/zinc_lib/atomic-groups.pl b/Perl/demos/Tk/demos/zinc_lib/atomic-groups.pl
deleted file mode 100644
index 67c019c..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/atomic-groups.pl
+++ /dev/null
@@ -1,221 +0,0 @@
-#!/usr/bin/perl
-# $Id$
-# this simple sample has been developped by C. Mertz mertz@cena.fr
-
-package atomic_groups;
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-use Tk::Zinc;
-use Tk::Checkbutton;
-use Tk::Label;
-use strict;
-
-my $defaultfont = '-adobe-helvetica-bold-r-normal--*-120-*-*-*-*-*-*';
-my $mw = MainWindow->new();
-my $zinc = $mw->Zinc(-width => 500, -height => 350,
- -font => "10x20", # usually fonts are sets in resources
- # but for this example it is set in the code!
- -borderwidth => 0,
- )->pack;
-
-
-my $groups_group_atomicity = 0;
-my $red_group_atomicity = 0;
-my $green_group_atomicity = 0;
-
-my $display_clipping_item_background = 0;
-my $clip = 1;
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text =>
- "- There are 3 groups: a red group containing 2 redish objects,\n".
- "a green group containing 2 greenish objects,\n".
- "and groups_group containing both previous groups.\n".
- "- You can make some groups atomic or not by depressing \n".
- "the toggle buttons at the bottom of the window\n".
- "- Try and then click on some items to observe that callbacks\n".
- " are then different: they modify either the item, or 2 items of\n".
- " a group or all items",
- -anchor => 'nw',
- -position => [10, 10]);
-
-
-############### creating the top group with its bindings ###############################
-my $groups_group = $zinc->add('group', 1, -visible => 1,
- -atomic => $groups_group_atomicity,
- -tags => [ 'groups_group' ]);
-
-# the following callbacks will be called only if 'groups_group' IS atomic
-$zinc->bind($groups_group, '<1>', \&modify_bitmap_bg);
-$zinc->bind($groups_group, '<ButtonRelease-1>', \&modify_bitmap_bg);
-
-############### creating the red_group, with its binding and its content ################
-# the red_group may be atomic, that is is makes all children as a single object
-# and sensitive to red_group callbacks
-my $red_group = $zinc->add('group', $groups_group,
- -visible => 1,
- -atomic => $red_group_atomicity,
- -sensitive => 1,
- -tags => ['red_group'],
- );
-# the following callbacks will be called only if 'groups_group' IS NOT-atomic
-# and if 'red_group' IS atomic
-$zinc->bind($red_group, '<1>', sub { &modify_item_lines($red_group)} );
-$zinc->bind($red_group, '<ButtonRelease-1>', sub { &modify_item_lines($red_group)} );
-
-
-my $rc = $zinc->add('arc', $red_group,
- [100, 200, 140, 240],
- -filled => 1, -fillcolor => "red2",
- -linewidth => 3, -linecolor => "white",
- -tags => [ 'red_circle' ],
- );
-
-my $rr = $zinc->add('rectangle', $red_group,
- [300, 200, 400,250],
- -filled => 1, -fillcolor => "red2",
- -linewidth => 3, -linecolor => "white",
- -tags => [ 'red_rectangle' ],
- );
-# the following callbacks will be called only if 'groups_group' IS NOT atomic
-# and if 'red_group' IS NOT atomic
-$zinc->bind($rc, '<1>', \&toggle_color);
-$zinc->bind($rc, '<ButtonRelease-1>', \&toggle_color);
-$zinc->bind($rr, '<1>', \&toggle_color);
-$zinc->bind($rr, '<ButtonRelease-1>', \&toggle_color);
-
-############### creating the green_group, with its binding and its content ################
-# the green_group may be atomic, that is is makes all children as a single object
-# and sensitive to green_group callbacks
-my $green_group = $zinc->add('group', $groups_group,
- -visible => 1,
- -atomic => $green_group_atomicity,
- -sensitive => 1,
- -tags => ['green_group'],
- );
-# the following callbacks will be called only if 'groups_group' IS NOT atomic
-# and if 'green_group' IS atomic
-$zinc->bind($green_group, '<1>', sub { &modify_item_lines($green_group) } );
-$zinc->bind($green_group, '<ButtonRelease-1>', sub { &modify_item_lines($green_group) } );
-
-my $gc = $zinc->add('arc', $green_group,
- [100,270, 140,310],
- -filled => 1, -fillcolor => "green2",
- -linewidth => 3, -linecolor => "white",
- -tags => [ 'green_circle' ],
- );
-
-my $gr = $zinc->add('rectangle', $green_group,
- [300,270, 400,320],
- -filled => 1, -fillcolor => "green2",
- -linewidth => 3, -linecolor => "white",
- -tags => [ 'green_rectangle' ],
- );
-# the following callbacks will be called only if 'groups_group' IS NOT atomic
-# and if 'green_group' IS NOT atomic
-$zinc->bind($gc, '<1>', \&toggle_color);
-$zinc->bind($gc, '<ButtonRelease-1>', \&toggle_color);
-$zinc->bind($gr, '<1>', \&toggle_color);
-$zinc->bind($gr, '<ButtonRelease-1>', \&toggle_color);
-
-
-
-my $current_bg = '';
-###################### groups_group callback ##############
-sub modify_bitmap_bg {
- if ($current_bg eq 'AlphaStipple2') {
- $current_bg = '';
- }
- else {
- $current_bg = 'AlphaStipple2';
- }
- foreach my $item ($rc, $rr, $gc, $gr) {
- $zinc->itemconfigure($item, -fillpattern => $current_bg);
- }
-}
-
-#################### red/green_group callback ##############
-sub modify_item_lines {
- my ($gr) = @_;
- my @children = $zinc->find('withtag', ".$gr*"); # we are using a pathtag (still undocumented feature of 3.2.6) to get items of an atomic group!
- # we could also temporary modify the groups (make it un-atomic) to get its child
-
- my $current_linewidth = $zinc->itemcget($children[0], -linewidth);
- if ($current_linewidth == 3) {
- $current_linewidth = 0;
- }
- else {
- $current_linewidth = 3;
- }
- foreach my $item (@children) {
- $zinc->itemconfigure($item, -linewidth => $current_linewidth);
- }
-
-}
-
-
-##################### items callback ######################
-sub toggle_color {
- my $item = $zinc->find('withtag', 'current');
- my $fillcolor = $zinc->itemcget($item, -fillcolor);
- my ($color,$num) = $fillcolor =~ /([a-z]+)(\d)/ ;
- if ($num == 2) {
- $num = 4;
- }
- else {
- $num = 2;
- }
- $zinc->itemconfigure($item, -fillcolor => "$color$num");
-}
-
-
-###################### toggle buttons at the bottom #######
-my $row = $mw->Frame()->pack();
-$row->Checkbutton(-text => 'groups_group is atomic',
- -variable => \$groups_group_atomicity,
- -command => sub { &atomic_or_not ($groups_group, \$groups_group_atomicity) },
- )->pack(-anchor => 'w');
-
-$row->Checkbutton(-text => 'red group is atomic ',
- -foreground => "red4",
- -variable => \$red_group_atomicity,
- -command => sub { &atomic_or_not ($red_group, \$red_group_atomicity) },
- )->pack(-anchor => 'w');
-
-$row->Checkbutton(-text => 'green group is atomic ',
- -foreground => "green4",
- -variable => \$green_group_atomicity,
- -command => sub { &atomic_or_not ($green_group, \$green_group_atomicity) },
- )->pack(-anchor => 'w');
-$row->Label()->pack(-anchor => 'w');
-$row->Label(-text => "Following command \"\$zinc->find('overlapping', 0,200,500,400)\" returns:")->pack(-anchor => 'w');
-my $label = $row->Label(-background => 'gray95')->pack(-anchor => 'w');
-
-
-sub atomic_or_not {
- my ($gr,$ref_atomic) = @_;
- my $atomic = ${$ref_atomic};
- $zinc->itemconfigure( $gr, -atomic => $atomic);
- &update_found_items;
-}
-
-##### to update the list of enclosed items
-sub update_found_items {
- $zinc->update; # to be sure eveyrthing has been updated inside zinc!
- my @found = $zinc->find('overlapping', 0,200,500,400);
- my $str = "";
- foreach my $item (@found) {
- my @tags = $zinc->itemcget($item, -tags);
- $str .= " " . $tags[0];
- }
- $label->configure (-text => $str);
-}
-
-# to init the list of enclosed items
-&update_found_items;
-
-Tk::MainLoop;
diff --git a/Perl/demos/Tk/demos/zinc_lib/clipping.pl b/Perl/demos/Tk/demos/zinc_lib/clipping.pl
deleted file mode 100644
index 4a320e0..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/clipping.pl
+++ /dev/null
@@ -1,150 +0,0 @@
-#!/usr/bin/perl
-# $Id$
-# this simple sample has been developped by C. Mertz mertz@cena.fr
-
-use Tk;
-use Tk::Zinc;
-use strict;
-use Tk::Checkbutton;
-
-package clipping;
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-my $defaultfont = '-adobe-helvetica-bold-r-normal--*-120-*-*-*-*-*-*';
-my $mw = MainWindow->new();
-my $zinc = $mw->Zinc(-width => 700, -height => 600,
- -font => "10x20", # usually fonts are sets in resources
- # but for this example it is set in the code!
- -borderwidth => 3, -relief => 'sunken',
- )->pack;
-
-my $display_clipping_item_background = 0;
-my $clip = 1;
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "You can drag and drop the objects.\n".
- "There are two groups of objects, a \"tan group\" and a \"blue group\".\n".
- "Try to move them and discover the clipping area which is a curve.\n".
- "with two contours",
- -anchor => 'nw',
- -position => [10, 10]);
-
-
-my $clipped_group = $zinc->add('group', 1, -visible => 1);
-
-my $clipping_item = $zinc->add('curve', $clipped_group,
- [10,100, 690,100, 690,590, 520,350,
- 350,590, 180,350, 10,590],
- -closed => 1,
- -priority => 1,
- -fillcolor => "tan2",
- -linewidth => 0,
- -filled => $display_clipping_item_background);
-$zinc->contour($clipping_item, "add", +1, [200,200, 500,200, 500,250, 200,250]);
-
-############### creating the tan_group objects ################
-# the tan_group is atomic, that is is makes all children as a single object
-# and sensitive to tan_group callbacks
-my $tan_group = $zinc->add('group', $clipped_group,
- -visible => 1,
- -atomic => 1,
- -sensitive => 1,
- );
-
-$zinc->add('arc', $tan_group,
- [200, 220, 280, 300],
- -filled => 1, -linewidth => 1,
- -startangle => 45, -extent => 270,
- -pieslice => 1, -closed => 1,
- -fillcolor => "tan",
- );
-
-$zinc->add('curve', $tan_group,
- [400,400, 440,450, 400,500, 500,500, 460,450, 500,400],
- -filled => 1, -fillcolor => "tan",
- -linecolor => "tan",
- );
-
-############### creating the blue_group objects ################
-# the blue_group is atomic too, that is is makes all children as a single object
-# and sensitive to blue_group callbacks
-my $blue_group = $zinc->add('group', $clipped_group,
- -visible => 1,
- -atomic => 1,
- -sensitive => 1,
- );
-
-$zinc->add('rectangle', $blue_group,
- [570,180, 470,280],
- -filled => 1, -linewidth => 1,
- -fillcolor => "blue2",
- );
-
-$zinc->add('curve', $blue_group,
- [200,400, 200,500, 300,500, 300,400, 300,300],
- -filled => 1, -fillcolor => "blue",
- -linewidth => 0,
- );
-
-
-$zinc->itemconfigure($clipped_group, -clip => $clipping_item);
-
-
-###################### drag and drop callbacks ############
-# for both tan_group and blue_group
-$zinc->bind($tan_group, '<ButtonPress-1>' => [\&press, $tan_group, \&motion]);
-$zinc->bind($tan_group, '<ButtonRelease-1>' => \&release);
-$zinc->bind($blue_group, '<ButtonPress-1>' => [\&press, $blue_group, \&motion]);
-$zinc->bind($blue_group, '<ButtonRelease-1>' => \&release);
-
-my ($x_orig, $y_orig);
-sub press {
- my ($zinc, $group, $action) = @_;
- my $ev = $zinc->XEvent();
- $x_orig = $ev->x;
- $y_orig = $ev->y;
- $zinc->Tk::bind('<Motion>', [$action, $group]);
-}
-
-sub motion {
- my ($zinc, $group) = @_;
- my $ev = $zinc->XEvent();
- my $x = $ev->x;
- my $y = $ev->y;
-
- $zinc->translate($group, $x-$x_orig, $y-$y_orig);
- $x_orig = $x;
- $y_orig = $y;
-}
-
-sub release {
- my ($zinc) = @_;
- $zinc->Tk::bind('<Motion>', '');
-}
-###################### toggle buttons at the bottom #######
-my $row = $mw->Frame()->pack();
-$row->Checkbutton(-text => 'Show clipping item',
- -variable => \$display_clipping_item_background,
- -command => \&display_clipping_area)->pack;
-
-$row->Checkbutton(-text => 'Clip',
- -variable => \$clip,
- -command => \&clip)->pack;
-
-sub display_clipping_area {
- $zinc->itemconfigure($clipping_item, -filled => $display_clipping_item_background);
-}
-
-sub clip {
- if ($clip) {
- $zinc->itemconfigure($clipped_group, -clip => $clipping_item);
- }
- else {
- $zinc->itemconfigure($clipped_group, -clip => undef);
- }
-}
-
-Tk::MainLoop;
diff --git a/Perl/demos/Tk/demos/zinc_lib/color-circular.pl b/Perl/demos/Tk/demos/zinc_lib/color-circular.pl
deleted file mode 100644
index 1ee1638..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/color-circular.pl
+++ /dev/null
@@ -1,75 +0,0 @@
-#!/usr/bin/perl
-# $Id$
-# these simple samples have been developped by C. Mertz mertz@cena.fr
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-use Tk::Zinc;
-use strict;
-
-my $defaultfont = '-adobe-helvetica-bold-r-normal--*-120-*-*-*-*-*-*';
-my $mw = MainWindow->new();
-my $zinc = $mw->Zinc(-width => 700, -height => 600,
- -borderwidth => 3, -relief => 'sunken',
- -render => 1, # for activating the openGL render
- )->pack;
-
-# This demo no more dies if there is no openGL. It simply displays
-# a string on the bootom of the window!
-
-
-$zinc->add('rectangle', 1, [10, 10, 80, 80], -fillcolor => "=radial 50 50 |red |blue", -filled => 1);
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "Radial variation from non-transparent red to non-transparent blue\nin a squarre. The gradient starts from the lower right corner.\n",
- -anchor => 'nw',
- -position => [120, 20]);
-
-$zinc->add('arc', 1, [10, 110, 90, 190], -fillcolor => "=radial 0 25 |red;40|blue;40", -filled => 1);
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "Radial variation from 40%transparent red to 40% transparent blue\nin a disc. The gradient starts in the middle between\nthe center on the bottom point",
- -anchor => 'nw',
- -position => [120, 120]);
-
-$zinc->add('arc', 1, [10, 210, 90, 290], -fillcolor => "=radial 0 0 |red;40|green;40 50|blue;40", -filled => 1);
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "A variation from 40%transparent red to 40% transparent blue.\n".
- "through a 40%green on the middle of the disc. The gradient is centered.",
- -anchor => 'nw',
- -position => [120, 220]);
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "Two overlaping radialy, transparently colored items on a white background",
- -anchor => 'nw',
- -position => [20, 320]);
-
-$zinc->add('rectangle', 1, [10, 340, 690, 590], -fillcolor => "white", -filled => 1);
-
-$zinc->add('rectangle', 1, [20, 365, 220, 565], -fillcolor => "=radial 0 0 |red;40|green;40 50|blue;40", -filled => 1);
-
-$zinc->add('arc', 1, [150, 365, 350, 565], -fillcolor => "=radial 0 0 |yellow;40|black;40 50|cyan;40", -filled => 1);
-
-$zinc->add('arc', 1, [280, 365, 480, 565], -fillcolor => "=radial 0 0 |black;100|black;100 20|white;40", -filled => 1, -linewidth => 0);
-
-$zinc->add('arc', 1, [480, 365, 580, 500], -fillcolor => "=radial -10 16 |black;100|white;40", -filled => 1);
-
-$zinc->add('arc', 1, [580, 410, 680, 580], -fillcolor => "=radial -40 -40 |black;70|white;20", -filled => 1);
-$zinc->add('arc', 1, [580, 410, 680, 580], -fillcolor => "=radial 40 40 |black;70|white;20", -filled => 1);
-
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "WITHOUT openGL, NO GRADIENT. SORRY!",
- -anchor => 'nw',
- -position => [20, 550]) unless $zinc->cget(-render);
-
-MainLoop;
-
diff --git a/Perl/demos/Tk/demos/zinc_lib/color-path-and-conic.pl b/Perl/demos/Tk/demos/zinc_lib/color-path-and-conic.pl
deleted file mode 100644
index 264811f..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/color-path-and-conic.pl
+++ /dev/null
@@ -1,78 +0,0 @@
-#!/usr/bin/perl
-# $Id$
-# these simple samples have been developped by C. Mertz mertz@cena.fr
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-use Tk::Zinc;
-use strict;
-
-my $defaultfont = '-adobe-helvetica-bold-r-normal--*-120-*-*-*-*-*-*';
-my $mw = MainWindow->new();
-my $zinc = $mw->Zinc(-width => 700, -height => 600,
- -borderwidth => 3, -relief => 'sunken',
- -render => 1, # for activating the openGL render
- )->pack;
-
-# This demo no more dies if there is no openGL. It simply displays
-# a string on the bootom of the window!
-
-
-$zinc->add('rectangle', 1, [10, 10, 80, 80], -fillcolor => "=path 0 0 |red |blue", -filled => 1);
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "Path variation from non-transparent red to non-transparent blue\nin a squarre. The gradient start at the middle of the bbox.",
- -anchor => 'nw',
- -position => [120, 20]);
-
-$zinc->add('arc', 1, [10, 110, 90, 190], -fillcolor => "=conical 135 |black;40|white;40", -filled => 1);
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "Conical variation from 40%transparent black to 40% transparent white\nin a disc, center in the middle of the bbox",
- -anchor => 'nw',
- -position => [120, 120]);
-
-
-$zinc->add('arc', 1, [10, 210, 90, 290], -fillcolor => "=path -30 +30 |red;40|green;40 50|blue;40", -filled => 1);
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "A path variation from 40%transparent red to 40% transparent blue.\n".
- "through a 40%green on the middle of the disc. The gradient center\nis toward the SW of the bbox.",
- -anchor => 'nw',
- -position => [120, 220]);
-
-
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "overlaping path and conical, transparently colored items on a white background",
- -anchor => 'nw',
- -position => [20, 320]);
-
-$zinc->add('rectangle', 1, [10, 340, 690, 590], -fillcolor => "white", -filled => 1);
-
-$zinc->add('rectangle', 1, [20, 365, 220, 565], -fillcolor => "=path -40 -40 |red;40|green;40 50|blue;40", -filled => 1);
-
-$zinc->add('arc', 1, [150, 365, 350, 565], -fillcolor => "=conical 20 -30 45 |yellow;40|black;40 50|cyan;40", -filled => 1);
-
-$zinc->add('arc', 1, [320, 365, 480, 565], -fillcolor => "=path 0 0 |black;100|black;100 20|white;40", -filled => 1, -linewidth => 0);
-
-#$zinc->add('arc', 1, [480, 365, 580, 500], -fillcolor => "=radial -10 16 |black;100|white;40", -filled => 1);
-
-$zinc->add('arc', 1, [580, 410, 680, 580], -fillcolor => "=conical -40 -40 135 |black;70|white;20", -filled => 1);
-#$zinc->add('arc', 1, [580, 410, 680, 580], -fillcolor => "=radial 40 40 |black;70|white;20", -filled => 1);
-
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "WITHOUT openGL, NO GRADIENT. SORRY!",
- -anchor => 'nw',
- -position => [20, 550]) unless $zinc->cget(-render);
-
-MainLoop;
-
diff --git a/Perl/demos/Tk/demos/zinc_lib/color-x.pl b/Perl/demos/Tk/demos/zinc_lib/color-x.pl
deleted file mode 100644
index 62937b2..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/color-x.pl
+++ /dev/null
@@ -1,94 +0,0 @@
-#!/usr/bin/perl
-# $Id$
-# these simple samples have been developped by C. Mertz mertz@cena.fr
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-use Tk::Zinc;
-use strict;
-
-my $defaultfont = '-adobe-helvetica-bold-r-normal--*-120-*-*-*-*-*-*';
-my $mw = MainWindow->new();
-my $zinc = $mw->Zinc(-width => 700, -height => 600,
- -borderwidth => 3, -relief => 'sunken',
- -render => 1, # for activating the openGL render
- )->pack;
-
-# This demo no more dies if there is no openGL. It simply displays
-# a string on the bootom of the window!
-
-$zinc->add('rectangle', 1, [10,10, 690, 50], -fillcolor => "=axial 0 | red | blue", -filled => 1);
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "A variation from non transparent red to non transparent blue.",
- -anchor => 'nw',
- -position => [20, 20]);
-
-
-$zinc->add('rectangle', 1, [10,60, 690, 100], -fillcolor => "=axial -30 0 30 0 | red | blue", -filled => 1);
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "The same with a reduced span.",
- -anchor => 'nw',
- -position => [20, 70]);
-
-
-$zinc->add('rectangle', 1, [10,110, 690, 150], -fillcolor => "=axial 0 |red;40|blue;40", -filled => 1);
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "A variation from 40%transparent red to 40% transparent blue.",
- -anchor => 'nw',
- -position => [20, 120]);
-
-
-$zinc->add('rectangle', 1, [10,160, 690, 200], -fillcolor => "=axial -30 0 30 0 |red;40|blue;40", -filled => 1);
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "The same with a reduced span.",
- -anchor => 'nw',
- -position => [20, 170]);
-
-
-# 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,
- -font => $defaultfont,
- -text => "A variation from 40%transparent red to 40% transparent blue.\n".
- "through a 40%green on the middle",
- -anchor => 'nw',
- -position => [20, 220]);
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "Two overlaping transparently colored rectangles on a white background",
- -anchor => 'nw',
- -position => [20, 320]);
-
-$zinc->add('rectangle', 1, [10, 340, 690, 590], -fillcolor => "white", -filled => 1);
-$zinc->add('rectangle', 1, [200, 350, 500, 580], -fillcolor => "red;40|green;40 50|blue;40", -filled => 1);
-
-$zinc->add('rectangle', 1, [10, 400, 690, 500], -fillcolor => "=axial 0 |yellow;40|black;40 50|cyan;40", -filled => 1);
-
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "WITHOUT openGL, NO GRADIENT. SORRY!",
- -anchor => 'nw',
- -position => [20, 550]) unless $zinc->cget(-render);
-
-
-
-MainLoop;
-
diff --git a/Perl/demos/Tk/demos/zinc_lib/color-y.pl b/Perl/demos/Tk/demos/zinc_lib/color-y.pl
deleted file mode 100644
index b33f269..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/color-y.pl
+++ /dev/null
@@ -1,91 +0,0 @@
-#!/usr/bin/perl
-# $Id$
-# these simple samples have been developped by C. Mertz mertz@cena.fr
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-use Tk::Zinc;
-use strict;
-
-my $defaultfont = '-adobe-helvetica-bold-r-normal--*-120-*-*-*-*-*-*';
-my $mw = MainWindow->new();
-my $zinc = $mw->Zinc(-width => 700, -height => 600,
- -borderwidth => 3, -relief => 'sunken',
- -render => 1, # for activating the openGL render
- )->pack;
-
-# This demo no more dies if there is no openGL. It simply displays
-# a string on the bootom of the window!
-
-
-$zinc->add('rectangle', 1, [10, 10, 340, 100], -fillcolor => "=axial 90 |red |blue", -filled => 1);
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "A variation from non transparent red\n to non transparent blue.",
- -anchor => 'nw',
- -position => [20, 20]);
-
-
-$zinc->add('rectangle', 1, [360, 10, 690, 100], -fillcolor => "=axial 0 30 0 -30 |red |blue", -filled => 1);
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "The same with a reduced span.",
- -anchor => 'nw',
- -position => [370, 20]);
-
-
-
-$zinc->add('rectangle', 1, [10,110, 330, 200], -fillcolor => "=axial 90|red;40 |blue;40", -filled => 1);
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "A variation from 40%transparent red\nto 40% transparent blue.",
- -anchor => 'nw',
- -position => [20, 120]);
-
-
-$zinc->add('rectangle', 1, [360,110, 690, 200], -fillcolor => "=axial 0 30 0 -30|red;40 |blue;40", -filled => 1);
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "The same with a reduced span.",
- -anchor => 'nw',
- -position => [370, 120]);
-
-
-$zinc->add('rectangle', 1, [10, 210, 690, 300], -fillcolor => "=axial 90 |red;40|green;40 50|blue;40", -filled => 1);
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "A variation from 40%transparent red to 40% transparent blue.\n".
- "through a 40%green on the middle",
- -anchor => 'nw',
- -position => [20, 220]);
-
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "Two overlaping transparently colored rectangles on a white background",
- -anchor => 'nw',
- -position => [20, 320]);
-
-$zinc->add('rectangle', 1, [10, 340, 690, 590], -fillcolor => "white", -filled => 1);
-$zinc->add('rectangle', 1, [200, 350, 500, 580], -fillcolor => "=axial 90 |red;40|green;40 50|blue;40", -filled => 1);
-
-$zinc->add('rectangle', 1, [10, 400, 690, 500], -fillcolor => "=axial 90 |yellow;40|black;40 50|cyan;40", -filled => 1);
-
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "WITHOUT openGL, NO GRADIENT. SORRY!",
- -anchor => 'nw',
- -position => [20, 550]) unless $zinc->cget(-render);
-
-
-
-MainLoop;
-
diff --git a/Perl/demos/Tk/demos/zinc_lib/contours.pl b/Perl/demos/Tk/demos/zinc_lib/contours.pl
deleted file mode 100644
index db0b960..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/contours.pl
+++ /dev/null
@@ -1,202 +0,0 @@
-#!/usr/bin/perl -w
-# $Id$
-# This simple demo has been developped by C. Mertz <mertz@cena.fr>
-
-package contours; # for avoiding symbol collision between different demos
-
-use Tk;
-use Tk::Zinc;
-
-use strict;
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-my $mw = MainWindow->new();
-
-# The explanation displayed when running this demo
-my $text = $mw->Text(-relief => 'sunken', -borderwidth => 2,
- -setgrid => 'true', -height => 9);
-$text->pack(qw/-expand yes -fill both/);
-
-$text->insert('0.0',
-'All visibles items are made by combining 2 items using contours:
- - the firebrick curve1 has been holed using a addhole with a circle,
- - the lightblue curve2 has been "mickey-moused" by adding two circles,
- - the yellow curve3 is the union with a disjoint circle,
- - the grey curve4 is combined with 7 circles, with \'positive\' -fillrule.
-The following operations are possible:
- - "Mouse Button 1" for dragging objects.
- - "Mouse Button 1" for dragging the black handle and
- modifying the grey curve contour.');
-
-# Creating the zinc widget
-my $zinc = $mw->Zinc(-width => 600, -height => 500,
- -font => "10x20", # usually fonts are sets in resources
- # but for this example it is set in the code!
- -borderwidth => 3, -relief => 'sunken',
- )->pack;
-
-
-# Creation of 2 items NOT visible, but used for creating visible
-# curves[1-5] with more than one contours.
-# The center of these 2 items is 200,100
-my $curve0 = $zinc->add('curve', 1, [ [300,0], [400,100, 'c'], [300,200], [200,300,'c'], [100,200], [0,100,'c'], [100,0], ],
- -closed => 1, -visible => 0, -filled => 1,
- );
-my $cercle100 = $zinc->add('arc', 1, [130,30, 280,180],
- -visible => 0,
- );
-
-# cloning curve0 as curve1 and moving it
-my $curve1 = $zinc->clone($curve0, -visible => 1, -fillcolor => "firebrick1");
-# adding a 'difference' contour to the curve1
-$zinc->contour($curve1, 'add', +1, $cercle100);
-
-
-# cloning curve0 as curve2 and moving it
-# creating a curve without contour to control contour clockwise/counterclockwise
-my $curve2 = $zinc->add('curve', 1, [], -closed => 1, -filled => 1,
- -visible => 1, -fillcolor => "lightblue2", -fillrule => 'positive');
-$zinc->contour($curve2, 'add', -1, $curve0); ## why must the flag be -1 and not -1 !?
-# adding the left ear of mickey mouse!
-$zinc->translate($curve2,100,90);
-# adding the right ear of mickey mouse!
-$zinc->contour($curve2, 'add', +1, $cercle100);
-
-$zinc->translate($curve2,-200,0);
-# adding an 'intersection' contour to the curve2
-$zinc->contour($curve2, 'add', +1, $cercle100);
-
-# ... translate to make it more visible
-$zinc->translate($curve2, 320,20);
-
-
-# cloning curve0 as curve3 and moving it
-my $curve3 = $zinc->clone($curve0, -visible => 1, -fillcolor => "yellow3");
-$zinc->translate($curve3,0,290);
-# adding an 'union' contour to the curve3
-$zinc->contour($curve3, 'add', +1, $cercle100);
-# ... translate to make it more visible
-$zinc->translate($curve3, -130,00);
-
-
-
-
-# cloning curve0 as curve4 and moving it slightly
-my $curve4 = $zinc->clone($curve0, -visible => 1, -fillcolor => "grey50",
- -tags => ["grouped"],
- -fillrule => 'positive',
- # the tag "grouped" is used for both curve4 and
- # a handle (see just below)
- # It is used for translating both easily
- );
-
-my $index = 2; ## index of the vertex associated to the handle
-my ($x,$y) = $zinc->coords($curve4,0,$index);
-my $handle = $zinc->add('rectangle', 1, [$x-5,$y-5,$x+5,$y+5],
- -fillcolor => 'black', -filled => 1,
- -tags => ["grouped"],
- );
-
-# adding a 'difference' contour to the curve4
-$zinc->contour($curve4, 'add', +1, $cercle100);
-$zinc->translate('grouped',110,0);
-$zinc->contour($curve4, 'add', +1, $cercle100);
-$zinc->translate('grouped',-220,0);
-$zinc->contour($curve4, 'add', +1, $cercle100);
-$zinc->translate('grouped',110,80);
-$zinc->contour($curve4, 'add', -1, $cercle100);
-$zinc->translate('grouped',0,-160);
-$zinc->contour($curve4, 'add', +1, $cercle100);
-
-$zinc->translate('grouped',200,80);
-$zinc->contour($curve4, 'add', +1, $cercle100);
-$zinc->translate('grouped',-350,0);
-$zinc->contour($curve4, 'add', +1, $cercle100);
-
-$zinc->translate('grouped',350,250);
-#$zinc->lower('grouped');
-
-# Deleting no more usefull items: curve0 and cercle100:
-$zinc->remove($curve0, $cercle100);
-
-$zinc->raise($curve1);
-
-# adding drag and drop callback to each visible curve!
-foreach my $item ($curve1, $curve2, $curve3, $curve4) {
- # Some bindings for dragging the items
- $zinc->bind($item, '<ButtonPress-1>' => [\&press, $item, \&motion]);
- $zinc->bind($item, '<ButtonRelease-1>' => \&release);
-}
-
-# adding drag and drop on curve4 which also moves handle
-$zinc->bind($curve4, '<ButtonPress-1>' => [\&press, $curve4, \&motionWithHandle]);
-$zinc->bind($curve4, '<ButtonRelease-1>' => \&release);
-
-# adding drag and drop on handle which also modify curve4
-$zinc->bind($handle, '<ButtonPress-1>' => [\&press, $handle, \&moveHandle]);
-$zinc->bind($handle, '<ButtonRelease-1>' => \&release);
-
-# callback for starting a drag
-my ($x_orig, $y_orig);
-sub press {
- my ($zinc, $item, $action) = @_;
- my $ev = $zinc->XEvent();
- $x_orig = $ev->x;
- $y_orig = $ev->y;
- $zinc->Tk::bind('<Motion>', [$action, $item]);
-}
-
-# Callback for moving an item
-sub motion {
- my ($zinc, $item) = @_;
- my $ev = $zinc->XEvent();
- my $x = $ev->x;
- my $y = $ev->y;
-
- $zinc->translate($item, $x-$x_orig, $y-$y_orig);
- $x_orig = $x;
- $y_orig = $y;
-}
-
-# Callback for moving an item and its handle
-sub motionWithHandle {
- my ($zinc, $item) = @_;
- my $ev = $zinc->XEvent();
- my $x = $ev->x;
- my $y = $ev->y;
-
- my ($tag) = $zinc->itemcget($item, -tags);
- $zinc->translate($tag, $x-$x_orig, $y-$y_orig);
- $x_orig = $x;
- $y_orig = $y;
-}
-
-# Callback for moving the handle and modifying curve4
-# this code is far from being generic. Only for demonstrating how we can
-# modify a contour with a unique handle!
-sub moveHandle {
- my ($zinc, $handle) = @_;
- my $ev = $zinc->XEvent();
- my $x = $ev->x;
- my $y = $ev->y;
-
- $zinc->translate($handle, $x-$x_orig, $y-$y_orig);
-
- my ($vertxX,$vertxY) = $zinc->coords($curve4,0,$index);
- $zinc->coords($curve4,0,$index, [$vertxX+($x-$x_orig), $vertxY+($y-$y_orig)]);
- $x_orig = $x;
- $y_orig = $y;
-}
-
-# Callback when releasing the mouse button. It removes any motion callback
-sub release {
- my ($zinc) = @_;
- $zinc->Tk::bind('<Motion>', '');
-}
-
-Tk::MainLoop();
-
-
-1;
diff --git a/Perl/demos/Tk/demos/zinc_lib/counter.pl b/Perl/demos/Tk/demos/zinc_lib/counter.pl
deleted file mode 100644
index a0e9534..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/counter.pl
+++ /dev/null
@@ -1,440 +0,0 @@
-#!/usr/bin/perl
-# This simple demo has been developped by C. Schlienger <celine@intuilab.com>
-
-package counter; # for avoiding symbol collision between different demos
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-use Tk::Zinc;
-use strict;
-use constant;
-
-my constant $PI=3.1416;
-
-my $boldfont = '-adobe-helvetica-bold-r-normal--20-240-100-100-p-182-iso8859-1';
-
-my $mw = MainWindow->new();
-
-###################################################
-# Zinc
-###################################################
-
-my $zinc = $mw->Zinc(-width => 700, -height => 400,
- -font => "10x20",
- -borderwidth => 3,
- -relief => 'sunken',
- -render => 1,
- )->pack;
-
-if ($zinc->cget(-render)) {
- $zinc->add('rectangle', 1,
- [0,0,700,400],
- -filled => 1, -linewidth => 0,
- -fillcolor => "=axial 90 |red;40|green;40 50|blue;40"
- );
-} else { ## no openGL rendering!
- # creating a curve in the background to demonstrate the clipping
- # of the hole in the counter
- $zinc->add('curve', 1, [30,30, 350,150, 670,30, 400,200, 670,370, 350,250, 30,370, 300,200, 30,30],
- -filled => 1,
- -fillcolor => "tan",
- );
-}
-
-# The explanation displayed when running this demo
-$zinc->add('text', 1,
- -position=> [10,10],
- -text => 'This toy-appli shows a simple counter. It is made thanks
-to clipping and contours : this is the only way to do this.
-You can drag the counter. Observe that the color of the background
-of the counter is the same as the one of the window (use of clips)',
- -font => "10x20",
- );
-
-###################################################
-# Les positions
-###################################################
-
-#--------------------------------
-# Carre dans lequel sera inscrit le cercle du compteur
-#---------------------------------
-
-my $x0=250;
-my $y0=100;
-my $x1=$x0+200;
-my $y1=$y0+200;
-
-#--------------------------------
-# Rectangle dans lequel defileront les chiffres
-#---------------------------------
-
-my $x2=$x0+50;
-my $y2=$y0+130;
-my $x3=$x1-50;
-my $y3=$y1-50;
-
-
-###################################################
-# Chiffres clippes
-###################################################
-
-my $general_group = $zinc->add('group',1, -visible => 1);
-
-my $clipped_group1 = $zinc->add('group',$general_group, -visible => 1);
-
-#--------------------------------
-# Clipping items
-#---------------------------------
-
-my $clipping_item1 = $zinc->add('curve', $clipped_group1,
- [$x2,$y2,$x3,$y2,$x3,$y3,$x2,$y3,$x2,$y2]
- );
-
-#--------------------------------
-# Clipped items
-#---------------------------------
-
-my $group1=$zinc->add('group',$clipped_group1);
-
-my $ecart=17;
-
-# Il y a deux listes de chifres pour centaines, dizaines, unites,
-# pour assurer l'enchainement des chiffres quand le temps passe
-# (cf. : actions automatiques)
-
-#--------------------------------
-# Centaines
-#---------------------------------
-
-my $cent = $zinc->add('group',$group1, -visible => 1,);
-my $xc=$x2+20;
-my $yc=$y2;
-
-
-my $nbc1=$zinc->add('text', $cent,
- -font => $boldfont,
- -text => "0
-1
-2
-3
-4
-5
-6
-7
-8
-9",
- -anchor => 'nw',
- -position => [$xc, $yc],
-);
-my $nbc2=$zinc->add('text', $cent,
- -font => $boldfont,
- -text => "0
-1
-2
-3
-4
-5
-6
-7
-8
-9",
- -anchor => 'nw',
- -position => [$xc, $yc+210],
-);
-#--------------------------------
-# Dixaines
-#---------------------------------
-
-my $dix = $zinc->add('group',$group1, -visible => 1);
-
-my $xd=$xc+30;
-my $yd=$y2;
-my $nbd1=$zinc->add('text', $dix,
- -font => $boldfont,
- -text => "0
-1
-2
-3
-4
-5
-6
-7
-8
-9",
- -anchor => 'nw',
- -position => [$xd,$yd]);
-
-my $nbd2=$zinc->add('text', $dix,
- -font => $boldfont,
- -text => "0
-1
-2
-3
-4
-5
-6
-7
-8
-9",
- -anchor => 'nw',
- -position => [$xd,$yd+210]);
-#--------------------------------
-# Unites
-#---------------------------------
-
-my $unit = $zinc->add('group',$group1, -visible => 1);
-my $xu=$xd+30;
-my $yu=$y2;
-my $nbu1=$zinc->add('text', $unit,
- -font => $boldfont,
- -text => "0
-1
-2
-3
-4
-5
-6
-7
-8
-9",
- -anchor => 'nw',
- -position => [$xu, $yu]);
-
-my $nbu2=$zinc->add('text', $unit,
- -font => $boldfont,
- -text => "0
-1
-2
-3
-4
-5
-6
-7
-8
-9",
- -anchor => 'nw',
- -position => [$xu, $yu+210]);
-
-#--------------------------------
-# Clip
-#---------------------------------
-
-$zinc->itemconfigure($clipped_group1, -clip => $clipping_item1);
-
-
-###################################################
-# Cadran clippe
-###################################################
-
-my $clipped_group2 = $zinc->add('group',$general_group, -visible => 1);
-
-#--------------------------------
-# Clipping items
-#---------------------------------
-
-my $clipping_item2 = $zinc->add('curve', $clipped_group2,
- [0,0,700,0,700,700,0,700,0,0],
- -linewidth=>0,
- );
-
-$zinc->contour($clipping_item2,"add",0,[$x2,$y2,$x3,$y2,$x3,$y3,$x2,$y3,$x2,$y2]);
-
-#--------------------------------
-# Clipped items
-#---------------------------------
-
-my $group2=$zinc->add('group',$clipped_group2);
-
-my $cercle=$zinc->add('arc',$group2,[$x0,$y0,$x1,$y1],
- -visible=>1,
- -filled=>1,
- -fillcolor=>"yellow",);
-
-my $fleche=$zinc-> add('curve', $group2, [$x0+40,$y0+40,$x1-100,$y1-25],
- -firstend => [10, 10, 10],
- -linewidth => 7,
- -linecolor=>"red",
- );
-
-#--------------------------------
-# Clip
-#---------------------------------
-
-$zinc->itemconfigure($clipped_group2, -clip => $clipping_item2);
-
-# this translation if for having an "interesting" background in the counter hole
-# when we do not have openGL and a gradient in the background
-$zinc->translate($general_group,0,21);
-
-###################################################
-# Actions automatiques
-###################################################
-
-#--------------------------------
-# Variables
-#---------------------------------
-# Pour le timer
-my $repeat=10;
-
-# Pour la rotation
-my @centre=($x1-100,$y1-25);
-my $pas=40;
-my $angle=+$PI/$pas;
-my $nb_tot=12;
-my $nb=0;
-
-# Pour la translation des centaines
-my @c_c1=$zinc->itemcget($nbc1,-position);
-my @c_c2=$zinc->itemcget($nbc2,-position);
-my $nbtour_cent=2;
-
-# Pour la translation des dizaines
-my @c_d1=$zinc->itemcget($nbd1,-position);
-my @c_d2=$zinc->itemcget($nbd2,-position);
-my $nbtour_dix=2;
-
-# Pour la translation des unites
-my @c_u1=$zinc->itemcget($nbu1,-position);
-my @c_u2=$zinc->itemcget($nbu2,-position);
-my $nbtour_unit=2;
-
-
-#--------------------------------
-# Timer
-#---------------------------------
-my $timer = $zinc->repeat($repeat, [\&refresh]);
-
-$mw->OnDestroy(\&destroyTimersub );
-
-my $timerIsDead = 0;
-sub destroyTimersub {
- $timerIsDead = 1;
- $mw->afterCancel($timer);
- # the timer is not really cancelled when using zinc-demos!
-}
-
-#--------------------------------
-# Actions
-#---------------------------------
-sub refresh {
- #--------------------------------
- # Rotation de la fleche
- #---------------------------------
- return if $timerIsDead; # the timer is still running when using zinc-demos!
- $zinc->rotate($fleche,$angle,$centre[0],$centre[1]);
- $nb+=1;
- if (($nb==$nb_tot)&&($angle==$PI/$pas))
- {
- $nb=0;
- $angle=-$PI/$pas;
- }
- else{
- if(($nb==$nb_tot)&&($angle==-$PI/$pas)){
- $nb=0;
- $angle=+$PI/$pas;
- }
- }
- #--------------------------------
- # Deplacement du texte
- #---------------------------------
-
- #--------------------------------
- # Centaines
- #---------------------------------
- $zinc->translate($cent,0,-0.01);
-
- my @coords_c1=$zinc->transform($cent,$group1,[$c_c1[0],$c_c1[1]]);
- if(int($coords_c1[1])==$yc-210){
- $zinc->itemconfigure($nbc1,-position=>[$xc,$yc+($nbtour_cent*210)]);
- $nbtour_cent+=1;
- @c_c1=$zinc->itemcget($nbc1,-position);
- }
-
- my @coords_c2=$zinc->transform($cent,$group1,[$c_c2[0],$c_c2[1]]);
- if($coords_c2[1]==$yc-210){
- $zinc->itemconfigure($nbc2,-position=>[$xc,$yc+($nbtour_cent*210)]);
- $nbtour_cent+=1;
- @c_c2=$zinc->itemcget($nbc2,-position);
- }
-
- #--------------------------------
- #Dixaines
- #---------------------------------
- $zinc->translate($dix,0,-0.1);
-
- my @coords_d1=$zinc->transform($dix,$group1,[$c_d1[0],$c_d1[1]]);
- if(int($coords_d1[1])==$yd-210){
- $zinc->itemconfigure($nbd1,-position=>[$xd,$yd+($nbtour_dix*210)]);
- $nbtour_dix+=1;
- @c_d1=$zinc->itemcget($nbd1,-position);
- }
-
- my @coords_d2=$zinc->transform($dix,$group1,[$c_d2[0],$c_d2[1]]);
- if($coords_d2[1]==$yd-210){
- $zinc->itemconfigure($nbd2,-position=>[$xd,$yd+($nbtour_dix*210)]);
- $nbtour_dix+=1;
- @c_d2=$zinc->itemcget($nbd2,-position);
- }
-
-
- #--------------------------------
- # Unites
- #---------------------------------
- $zinc->translate($unit,0,-1);
-
- my @coords_u1=$zinc->transform($unit,$group1,[$c_u1[0],$c_u1[1]]);
- if($coords_u1[1]==$yu-210){
- $zinc->itemconfigure($nbu1,-position=>[$xu,$yu+($nbtour_unit*210)]);
- $nbtour_unit+=1;
- @c_u1=$zinc->itemcget($nbu1,-position);
- }
-
- my @coords_u2=$zinc->transform($unit,$group1,[$c_u2[0],$c_u2[1]]);
- if($coords_u2[1]==$yu-210){
- $zinc->itemconfigure($nbu2,-position=>[$xu,$yu+($nbtour_unit*210)]);
- $nbtour_unit+=1;
- @c_u2=$zinc->itemcget($nbu2,-position);
- }
-
-}
-
-###################################################
-# Actions manuelles
-###################################################
-
-#---------------------------------------------
-# Drag and drop the counter
-#---------------------------------------------
-
-my ($prev_x, $prev_y);
-$zinc -> bind($cercle,'<ButtonPress-1>'=>[\&move_on] );
-
-
-#"move_on" state#
-sub move_on{
- $prev_x=$zinc->XEvent()->x;
- $prev_y=$zinc->XEvent()->y;
- # move the counter
- $zinc -> bind($cercle,'<Motion>'=> [\&move]);
- $zinc -> bind($cercle,'<ButtonRelease-1>'=> [\&move_off]); #"move_off" state
-}
-
-
-#"move_off" state#
-sub move_off{
- $zinc -> bind($cercle,'<Motion>'=>"");
- $zinc -> bind($cercle,'<ButtonRelease-1>'=>"");
-}
-
-#move the counter#
-sub move{
- my $x=$zinc->XEvent()->x,
- my $y=$zinc->XEvent()->y;
- $zinc->translate($clipped_group1,$x-$prev_x,$y-$prev_y);
- $zinc->translate($clipped_group2,$x-$prev_x,$y-$prev_y);
- ($prev_x,$prev_y) = ($x,$y);
-}
-
-Tk::MainLoop;
diff --git a/Perl/demos/Tk/demos/zinc_lib/curve_bezier.pl b/Perl/demos/Tk/demos/zinc_lib/curve_bezier.pl
deleted file mode 100644
index bc59863..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/curve_bezier.pl
+++ /dev/null
@@ -1,221 +0,0 @@
-#!/usr/bin/perl -w
-# $Id$
-# This simple demo has been developped by C. Mertz <mertz@cena.fr>
-
-####### This file has been initially inspired from svg examples
-
-package curveBezier;
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk::Zinc;
-
-
-my $mw = MainWindow->new();
-$mw->title('example of curves with cubic control points');
-
-my $text = $mw->Text (-relief => 'sunken', -borderwidth => 2,
- -setgrid => 'true', -height =>3);
-$text->pack(qw/-expand yes -fill both/);
-
-$text->insert('0.0',
-'6 examples of curves containing control points are displayed,
- with the list of control points written just below.
-You can move the handles to modify the bezier curves');
-
-
-my $zinc = $mw->Zinc(-width => 700, -height => 650,
- -font => "10x20",
- -font => "9x15",
- -borderwidth => 0,
- -backcolor => "white",
- -forecolor => "grey80",
- -render => 1, # this demo also works without openGL
- # with openGL, antialiasing makes the curves nicer
- )->pack;
-
-my $group = $zinc->add('group', 1);
-
-$zinc->add('text',$group, -position => [50,20], -anchor => 'w',
- -text => "Examples of curve items using cubic bezier control points",
- -color => "grey20");
-
-## Please note: much of the following items below could be computed
-$zinc->add('text',$group, -position => [25,270], -anchor => 'w', -tags => ['bezier1'], -color => "grey20");
-$zinc->add('curve',$group,[100, 200, 100, 100], -tags => ['line1', 'l1-2'], -linecolor => "#888888", -filled => 0, -linewidth => 2);
-$zinc->add('curve',$group,[400, 100, 400, 200], -tags => ['line1', 'l3-4'], -linecolor => "#888888", -filled => 0, -linewidth => 2);
-$zinc->add('curve',$group,[[100, 200], [100, 100, 'c'], [400, 100, 'c'], [400, 200]],
- -tags => ['bezier1'], -closed => 0, -linecolor => "red", -linewidth => 5);
-$zinc->add('arc',$group,[90, 190, 110, 210], -tags => ['handle1',"p1"], -filled => 1, -fillcolor => "#BBBBBB");
-$zinc->add('arc',$group,[90, 90, 110, 110], -tags => ['handle1',"p2"], -filled => 1, -linewidth => 0, -fillcolor => "grey80", -filled => 1);
-$zinc->add('arc',$group,[390, 90, 410, 110], -tags => ['handle1',"p3"], -filled => 1, -linewidth => 0, -fillcolor => "grey80", -filled => 1);
-$zinc->add('arc',$group,[390, 190, 410, 210], -tags => ['handle1',"p4"], -filled => 1, -fillcolor => "#BBBBBB");
-
-$zinc->add('text',$group, -position => [570,270], -anchor => 'w', -tags => ['bezier2'], -color => "grey20");
-$zinc->add('curve',$group,[600, 200, 675, 100], -tags => ['line2', 'l1-2'], -linecolor => "#888888", -linewidth => 2);
-$zinc->add('curve',$group,[975, 100, 900, 200], -tags => ['line2', 'l3-4'], -linecolor => "#888888", -linewidth => 2);
-$zinc->add('curve',$group,[[600, 200], [675, 100, 'c'], [975, 100, 'c'], [900, 200]],
- -tags => ['bezier2'], -closed => 0, -linecolor => "red", -linewidth => 5);
-$zinc->add('arc',$group,[590, 190, 610, 210], -tags => ['handle2',"p1"], -filled => 1, -linecolor => "grey80", -linewidth => 2);
-$zinc->add('arc',$group,[665, 90, 685, 110], -tags => ['handle2',"p2"], -filled => 1, -linewidth => 0, -fillcolor => "grey80");
-$zinc->add('arc',$group,[965, 90, 985, 110], -tags => ['handle2',"p3"], -filled => 1, -linewidth => 0, -fillcolor => "grey80");
-$zinc->add('arc',$group,[890, 190, 910, 210], -tags => ['handle2',"p4"], -filled => 1, -linecolor => "grey80", -linewidth => 2);
-
-$zinc->add('text',$group, -position => [25,570], -anchor => 'w', -tags => ['bezier3'], -color => "grey20");
-$zinc->add('curve',$group,[100, 500, 25, 400], -tags => ['line3', 'l1-2'], -linecolor => "#888888", -linewidth => 2);
-$zinc->add('curve',$group,[475, 400, 400, 500], -tags => ['line3', 'l3-4'], -linecolor => "#888888", -linewidth => 2);
-$zinc->add('curve',$group,[[100, 500], [25, 400, 'c'], [475, 400, 'c'], [400, 500]],
- -tags => ['bezier3'], -closed => 0, -linecolor => "red", -linewidth => 5);
-$zinc->add('arc',$group,[90, 490, 110, 510], -tags => ['handle3',"p1"], -filled => 1, -linecolor => "grey80", -linewidth => 2);
-$zinc->add('arc',$group,[15, 390, 35, 410], -tags => ['handle3',"p2"], -filled => 1, -linewidth => 0, -fillcolor => "grey80", );
-$zinc->add('arc',$group,[465, 390, 485, 410], -tags => ['handle3',"p3"], -filled => 1, -linewidth => 0, -fillcolor => "grey80", );
-$zinc->add('arc',$group,[390, 490, 410, 510], -tags => ['handle3',"p4"], -filled => 1, -linecolor => "grey80", -linewidth => 2);
-
-$zinc->add('text',$group, -position => [570,570], -anchor => 'w', -tags => ['bezier4'], -color => "grey20");
-$zinc->add('curve',$group,[600, 500, 600, 350], -tags => ['line4', 'l1-2'], -linecolor => "#888888", -linewidth => 2);
-$zinc->add('curve',$group,[900, 650, 900, 500], -tags => ['line4', 'l3-4'], -linecolor => "#888888", -linewidth => 2);
-$zinc->add('curve',$group,[[600, 500], [600, 350, 'c'], [900, 650, 'c'], [900, 500]], -tags => ['bezier4'], -closed => 0, -linecolor => "red", -linewidth => 5);
-$zinc->add('arc',$group,[590, 490, 610, 510], -tags => ['handle4',"p1"], -filled => 1, -linecolor => "grey80", -linewidth => 2);
-$zinc->add('arc',$group,[590, 340, 610, 360], -tags => ['handle4',"p2"], -filled => 1, -linewidth => 0, -fillcolor => "grey80");
-$zinc->add('arc',$group,[890, 640, 910, 660], -tags => ['handle4',"p3"], -filled => 1, -linewidth => 0, -fillcolor => "grey80");
-$zinc->add('arc',$group,[890, 490, 910, 510], -tags => ['handle4',"p4"], -filled => 1, -linecolor => "grey80", -linewidth => 2);
-
-$zinc->add('text',$group, -position => [25,870], -anchor => 'w', -tags => ['bezier5'], -color => "grey20");
-$zinc->add('curve',$group,[100, 800, 175, 700], -tags => ['line5', 'l1-2'], -linecolor => "#888888", -filled => 0, -linewidth => 2);
-$zinc->add('curve',$group,[325, 700, 400, 800], -tags => ['line5', 'l3-4'], -linecolor => "#888888", -filled => 0, -linewidth => 2);
-$zinc->add('curve',$group,[[100, 800], [175, 700, 'c'], [325, 700, 'c'], [400, 800]],
- -tags => ['bezier5'], -closed => 0, -linecolor => "red", -linewidth => 5);
-$zinc->add('arc',$group,[90, 790, 110, 810], -tags => ['handle5',"p1"], -filled => 1, -linecolor => "grey80", -linewidth => 2);
-$zinc->add('arc',$group,[165, 690, 185, 710], -tags => ['handle5',"p2"], -filled => 1, -linewidth => 0, -fillcolor => "grey80", -filled => 1);
-$zinc->add('arc',$group,[315, 690, 335, 710], -tags => ['handle5',"p3"], -filled => 1, -linewidth => 0, -fillcolor => "grey80", -filled => 1);
-$zinc->add('arc',$group,[390, 790, 410, 810], -tags => ['handle5',"p4"], -filled => 1, -linecolor => "grey80", -linewidth => 2);
-
-$zinc->add('text',$group, -position => [570,980], -anchor => 'w', -tags => ['bezier6'], -color => "grey20");
-$zinc->add('curve',$group,[600, 800, 625, 700], -tags => ['line6', 'l1-2'], -linecolor => "#888888", -linewidth => 2);
-$zinc->add('curve',$group,[725, 700, 750, 800], -tags => ['line6', 'l3-4'], -linecolor => "#888888", -linewidth => 2);
-$zinc->add('curve',$group,[750, 800, 775, 900], -tags => ['line6', 'l4-5'], -linecolor => "#888888", -linewidth => 2);
-$zinc->add('curve',$group,[875, 900, 900, 800], -tags => ['line6', 'l6-7'], -linecolor => "#888888", -linewidth => 2);
-$zinc->add('curve',$group,[[600, 800], [625, 700, 'c'], [725, 700, 'c'], [750, 800], [775, 900, 'c'], [875, 900, 'c'], [900, 800]],
- -tags => ['bezier6'], -filled => 0, -closed => 0, -linecolor => "red", -linewidth => 5);
-$zinc->add('arc',$group,[590, 790, 610, 810], -tags => ['handle6',"p1"], -filled => 1, -linecolor => "grey80", -linewidth => 2);
-$zinc->add('arc',$group,[615, 690, 635, 710], -tags => ['handle6',"p2"], -filled => 1, -linewidth => 0, -fillcolor => "grey80");
-$zinc->add('arc',$group,[715, 690, 735, 710], -tags => ['handle6',"p3"], -filled => 1, -linewidth => 0, -fillcolor => "grey80");
-$zinc->add('arc',$group,[740, 790, 760, 810], -tags => ['handle6',"p4"], -filled => 1, -linecolor => "blue",-fillcolor => "blue", -linewidth => 2);
-$zinc->add('arc',$group,[766, 891, 784, 909], -tags => ['handle6',"p5"], -filled => 1, -linecolor => "grey80", -linewidth => 4);
-$zinc->add('arc',$group,[865, 890, 885, 910], -tags => ['handle6',"p6"], -filled => 1, -linewidth => 0, -fillcolor => "grey80");
-$zinc->add('arc',$group,[890, 790, 910, 810], -tags => ['handle6',"p7"], -filled => 1, -linecolor => "grey80", -linewidth => 2);
-
-$zinc->scale($group, 0.6, 0.6);
-
-## Set the text of the text item with a tag "tag"
-## to a human-readable form of the coords of the
-## corresponding curve with the same tag "tag"
-sub setText {
- my ($tag) = @_;
- my $textItem = $zinc->find("withtype", 'text', $tag);
- my $curveItem = $zinc->find("withtype", 'curve', $tag);
- my @coords = $zinc->coords($curveItem);
- my $count = 0;
- my $text = "[ ";
- while (@coords) {
- $refXYc = pop @coords;
- my $x=sprintf "%i", $refXYc->[0];
- my $y=sprintf "%i", $refXYc->[1];
- my $t=$refXYc->[2];
- $t = (defined $t) ? ", '".$t."'" : "" ;
- $text .= "[$x, $y$t]";
- if (@coords) { $text .= ", "; }
- if ($count and @coords) {
- $text .= "\n ";
- $count =0;
- } else {
- $count++;
- }
- }
- $text .= " ]";
- $zinc->itemconfigure($textItem, -text => $text);
-}
-
-foreach my $bezierCount (1..6) {
- &setText ("bezier".$bezierCount);
- my $curveItem = $zinc->find("withtype", 'curve', "bezier".$bezierCount);
- my @coords = $zinc->coords($curveItem);
-# print "$bezierCount : ", scalar @coords, "\n";
- $zinc->bind("handle$bezierCount", '<ButtonPress-1>', [\&press, \&motion]);
- $zinc->bind("handle$bezierCount", '<ButtonRelease-1>', [\&release]);
-}
-
-
-
-&Tk::MainLoop;
-
-
-##### bindings for moving the handles
-my ($cur_x, $cur_y,$item, $bezierNum, $ptNum);
-sub press {
- my ($zinc, $action) = @_;
- my $ev = $zinc->XEvent();
- $cur_x = $ev->x;
- $cur_y = $ev->y;
- $item = $zinc->find('withtag', 'current');
- $zinc->bind($item, '<Motion>', [$action]);
- foreach ( $zinc->gettags($item) ) {
- ## looking for the tag "handlei"
- if ( /^handle(\d+)$/ ) {
- $bezierNum = $1;
- }
- ## looking for the tag "pj"
- if ( /^p(\d+)$/ ) {
- $ptNum = $1;
- }
- }
-# print "bezierNum=$bezierNum ptNum=$ptNum\n";
-}
-
-sub motion {
- my ($zinc) = @_;
- my $ev = $zinc->XEvent();
- my $lx = $ev->x;
- my $ly = $ev->y;
- my ($dx,$dy) = $zinc->transform($group, [$lx-$cur_x, $ly-$cur_y]);
- &moveHandle($item,$dx,$dy);
- my ($pt1,$pt2) = $zinc->coords($item);
-# print "coords=",@{$pt1}, " ",@{$pt2},"\n";
- $cur_x = $lx;
- $cur_y = $ly;
-}
-
-sub release {
- my ($zinc) = @_;
- $zinc->bind($item,'<Motion>', '');
- $item = "";
-}
-
-sub moveHandle {
- my ($item,$dx,$dy) = @_;
- my ($pt1,$pt2) = $zinc->coords($item);
- ## modifying the handle coords
- $zinc->coords($item, [ $pt1->[0]+$dx, $pt1->[1]+$dy, $pt2->[0]+$dx, $pt2->[1]+$dy]);
- my $prevPtNum = $ptNum-1;
- # there should only be one such item!
- my $lineA = $zinc->find("withtag", "line$bezierNum && l$prevPtNum-$ptNum");
- if (defined $lineA) {
- my ($x,$y) = $zinc->coords($lineA,0,1); # to get the 2nd point coords
- $zinc->coords($lineA, 0,1, [ $x+$dx, $y+$dy ]);
- }
-
- my $nextPtNum = $ptNum+1;
- # there should only be one such item:
- my ($lineB) = $zinc->find("withtag", "line$bezierNum && l$ptNum-$nextPtNum");
- if (defined $lineB) {
- my ($x,$y) = $zinc->coords($lineB,0,0); # to get the 1st point coords
- $zinc->coords($lineB, 0,0, [ $x+$dx, $y+$dy ] );
- }
-
- my ($x,$y,$control) = $zinc->coords("bezier$bezierNum", 0,$ptNum-1);
- $zinc->coords("bezier$bezierNum", 0,$ptNum-1, [ [$x+$dx, $y+$dy, $control] ] );
- &setText ("bezier$bezierNum");
-
-}
-
diff --git a/Perl/demos/Tk/demos/zinc_lib/fillrule.pl b/Perl/demos/Tk/demos/zinc_lib/fillrule.pl
deleted file mode 100644
index 08ec781..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/fillrule.pl
+++ /dev/null
@@ -1,101 +0,0 @@
-#!/usr/bin/perl -w
-# $Id$
-# This simple demo has been developped by C. Mertz <mertz@cena.fr>
-
-####### This file has been largely inspired from figure 11-3
-####### of "The OpenGL Programming Guide 3rd Edition, The
-####### Official Guide to Learning OpenGL Version 1.2", ISBN 0201604582
-
-####### it illustrates the use of :
-####### -fillrule attribute of curves
-####### contour, coords and clone method
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk::Zinc;
-
-
-my $mw = MainWindow->new();
-$mw->title('example of multiple contours and fillrule usage');
-
-my $zinc = $mw->Zinc(-width => 510, -height => 630,
- -font => "10x20",
- -font => "9x15",
- -borderwidth => 0,
- -backcolor => "white",
- )->pack;
-
-$zinc->add('text', 1, -position => [20,8], -text => "This (still static) example reproduces figure 11-3
-of \"The OpenGL Programming Guide 3rd Edition\" V 1.2");
-
-my $group = $zinc->add('group', 1);
-
-my $g1 = $zinc->add('group', $group);
-my $curve1 = $zinc->add('curve',$g1, []);
-$zinc->contour($curve1, "add", +1, [ 0,0, 0,120, 120,120, 120,0, 0,0]);
-$zinc->contour($curve1, "add", +1, [ 20,20, 20,100, 100,100, 100,20, 20,20]);
-$zinc->contour($curve1, "add", +1, [ 40,40, 40,80, 80,80, 80,40, 40,40]);
-$zinc->translate($g1, 40,40);
-
-
-my $g2 = $zinc->add('group', $group);
-my $curve2 = $zinc->add('curve',$g2, []);
-$zinc->contour($curve2, "add", +1, [ 0,0, 0,120, 120,120, 120,0, 0,0]);
-$zinc->contour($curve2, "add", -1, [ 20,20, 20,100, 100,100, 100,20, 20,20]);
-$zinc->contour($curve2, "add", -1, [ 40,40, 40,80, 80,80, 80,40, 40,40]);
-$zinc->translate($g2, 200,40);
-
-
-my $g3 = $zinc->add('group', $group);
-my $curve3 = $zinc->add('curve',$g3, []);
-$zinc->contour($curve3, "add", +1, [ 20,0, 20,120, 100,120, 100,0, 20,0]);
-$zinc->contour($curve3, "add", +1, [ 40,20, 60,120, 80,20, 40,20]);
-$zinc->contour($curve3, "add", +1, [ 0,60, 0,80, 120,80, 120,60, 0,60]);
-$zinc->translate($g3, 360,40);
-
-my $g4 = $zinc->add('group', $group);
-my $curve4 = $zinc->add('curve',$g4, []);
-$zinc->contour($curve4, "add", +1, [ 0,0, 0,140, 140,140, 140,60, 60,60, 60,80, 80,80, 80,40, 40,40,
- 40,100, 100,100, 100,20, 20,20,
- 20,120, 120,120, 120,0, 0,0]);
-$zinc->translate($g4, 520,40);
-
-$zinc->scale($group, 0.6, 0.6);
-$zinc->translate($group, 80,20);
-
-$zinc->add('text',$group, -position => [-110, 40], -text => "contours\nand\nwinding\nnumbers");
-$zinc->add('text',$group, -position => [-110, 170], -text => "winding\nrules");
-my $dy = 0;
-foreach my $fillrule ('odd', 'nonzero', 'positive', 'negative', 'abs_geq_2') {
- $dy += 160;
- $zinc->add('text',$group, -position => [-110, 100+$dy], -text => $fillrule eq 'odd' ? "odd\n(default)" : $fillrule);
- foreach my $item ($curve1, $curve2, $curve3, $curve4) {
- my $clone = $zinc->clone($item, -fillrule => $fillrule, -filled => 1);
- $zinc->translate($clone, 0,$dy);
- }
-}
-
-# creating simple lines with arrows under each curves
-foreach my $item ($curve1, $curve2, $curve3, $curve4) {
- my $contour_number = $zinc->contour($item);
-# print "$item => contour_number=$contour_number\n";
- foreach my $n (0..$contour_number-1) {
- my @points = $zinc->coords($item,$n);
-# print " ",$#points,"points\n";
- foreach my $i (0 .. $#points-1) {
-# print " line $i ",$i+1,"\n";
- $firstpoint = $points[$i];
- $lastpoint = $points[$i+1];
- $middlepoint = [$firstpoint->[0]+($lastpoint->[0]-$firstpoint->[0])/1.5,
- $firstpoint->[1]+($lastpoint->[1]-$firstpoint->[1])/1.5];
- $zinc->add("curve", $zinc->group($item),
- [ $firstpoint, $middlepoint],
- -lastend => [7,10,4]);
- }
- }
-}
-&Tk::MainLoop;
-
-
-
diff --git a/Perl/demos/Tk/demos/zinc_lib/groups_in_ATC_strips.pl b/Perl/demos/Tk/demos/zinc_lib/groups_in_ATC_strips.pl
deleted file mode 100644
index 74cc71c..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/groups_in_ATC_strips.pl
+++ /dev/null
@@ -1,910 +0,0 @@
-#!/usr/bin/perl -w
-#-----------------------------------------------------------------------------------
-#
-# Copyright (C) 2002
-# Centre d'Études de la Navigation Aérienne
-#
-# Authors: Jean-Luc Vinot <vinot@cena.fr> for whole graphic design and coding
-# Christophe Mertz <mertz@cena.fr> for adding simple animations
-# and integration in zinc-demos
-# This integration is still not perfect and requires an extension in zinc
-# We must know if a neamed gradient already exists, when launching
-# many time the same demo in the same process!
-#
-# $Id$
-#-----------------------------------------------------------------------------------
-# This small application illustrates both the use of groups in combination
-# of -composescale attributes and an implementation of kind of air traffic
-# control electronic strips.
-# However it is only a simplified example given as is, without any immediate usage!
-#
-# 3 strips formats are accessible through "+" / "-" buttons on the right side
-#
-# 1. small-format: with 2 lines of info, and reduced length
-#
-# 2. normal-format: with 3 lines of info, full length
-#
-# 3. extended-format: with 3 lines of infos, full length
-# the 3 lines are zoomed
-# an additionnel 4th lone is displayed
-#
-# An additionnal 4th format (micro-format) is available when double-clicking somewhere...
-#
-# Strips can be moved around by drag&drop from the callsign
-#
-# When changing size, strips are animated. The animation is a very simple one,
-# which should be enhanced.... You can change the animation parameters, by modifyng
-# $delay and $steps.
-#
-#-----------------------------------------------------------------------------------
-
-package groups_in_ATC_strips; # for avoiding symbol collision between different demos
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-use Tk::Zinc;
-use strict;
-
-$| = 1;
-
-
-my @stripGradiants;
-my %stripFontset;
-my %textures;
-
-my $oldfkey;
-my ($dx, $dy);
-
-my $delay = 50; # ms between each animation steps
-my $steps = 6; # number of steps for the animation
-my %scales; # this hash just memorizes the current x and y scaling ratio
- # In a real appli, this should be memorized in strip objects
-
-#----------------------
-# configuration data
-#----------------------
-my $fnb10 = 'cenapii-digistrips-b10';
-my $fnb10c = 'cenapii-digistrips-b10c';
-my $fnb11 = 'cenapii-digistrips-b11';
-my $fnb12 = 'cenapii-digistrips-b12';
-my $fnb15 = 'cenapii-radar-b15';
-my $fnm20 = 'cenapii-radar-m20';
-my $fne18 = 'cenapii-radar-m18';
-
-my @ratio2fontset = ([1.2, 'normal'],
- [10, 'large']);
-
-my $mwidth = 700;
-my $mheight = 500;
-
-my %stripstyle = (-gradset => {'idnt' => '=axial 90 |#ffffff 0|#ffeedd 30|#e9d1ca 90|#e9a89a',
- 'back' => '=axial 0 |#c1daff|#8aaaff',
- ## the following shadow gradient is sub-optimal
- 'shad' => '=path -40 -40 |#000000;50 0|#000000;50 92|#000000;0 100',
- 'btn_outside' => '=axial 0 |#ffeedd|#8a9acc',
- 'btn_inside' => '=axial 180 |#ffeedd|#8a9acc',
- 'ch1' => '=axial 0 |#8aaaff|#5B76ED',
- },
-
- -fontset => {'normal' => {'callsign' => $fnb15,
- 'type1' => $fnb12,
- 'type2' => $fnb10,
- 'type3' => $fnb10c,
- },
-
- 'large' => {'callsign' => $fnm20,
- 'type1' => $fne18,
- 'type2' => $fnb15,
- 'type3' => $fnb12,
- },
- },
-
- -width => 340,
- -height => 86,
- -shadowcoords => [8, 8, 374, 94],
- -shadowcolor => 'shad',
-
- -strip => {-linewidth => 3,
- -linecolor => '#aaccff',
- -fillcolor => 'back',
- -relief => 'roundraised',
- },
-
- -buttons => {-coords => [340, 0],
- -clipcoords => [0, 0, 90, 83],
- -zone => {-coords => [0, 0, 26, 85],
- -fillcolor => 'btn_outside',
- -linewidth => 0,
- },
-
- -btns => {'btnup' => {-coords => [0, 0, 26, 43],
- -arrow => [14, 2, 24, 40,
- 1, 40, 14, 2],
- -linewidth => 1,
- -linecolor => '#aabadd',
- -fillcolor => 'btn_inside',
- -label => {-coords => [13, 27],
- -text => "+",
- -font => $fnm20,
- -color => '#ffffff',
- -anchor => 'center',
- },
- },
-
- 'btndn' => {-coords => [0, 43, 26, 86],
- -arrow => [14, 83, 24, 43,
- 1, 43, 14, 83],
- -linewidth => 1,
- -linecolor => '#aabadd',
- -fillcolor => 'btn_inside',
- -label => {-coords => [13, 56],
- -text => "-",
- -font => $fnm20,
- -color => '#ffffff',
- -anchor => 'center',
- },
- },
- },
- },
-
- -clipcoords => [3, 3, 332, 80],
- -zones => {'ident' => {-coords => [3, 3, 90, 50],
- -atomic => 1,
- -priority => 200,
- -sensitive => 1,
- -tags => "move",
- -linewidth => 1,
- -filled => 1,
- -relief => 'sunken',
- -linecolor => '#ffeedd',
- -fillcolor => 'idnt',
- -fields => {-callsign => {-coords => [10, 18],
- -font => 'callsign',
- -text => 'EWG361',
- -anchor => 'w',
- -color => '#000000',
- },
- -company => {-coords => [10, 34],
- -font => 'type2',
- -text => 'Eurowing',
- -anchor => 'w',
- -color => '#444444',
- },
- },
- },
- 'input' => {-coords => [3, 3, 334, 82],
- -atomic => 1,
- -priority => 100,
- -sensitive => 1,
- -tags => "scale",
- -linewidth => 0,
- -filled => 1,
- -relief => 'flat',
- -linecolor => 'white',
- -fillcolor => 'back', #'#afb2cc',
- -fields => {-type => {-coords => [100, 18],
- -font => 'type1',
- -text => 'TYPA',
- -anchor => 'w',
- -color => '#444444',
- },
- -cfmu => {-coords => [200, 18],
- -font => 'type1',
- -text => '08:26',
- -anchor => 'e',
- -color => '#444444',
- },
- -ptsid => {-coords => [100, 40],
- -font => 'type2',
- -text => 'NIPOR',
- -anchor => 'w',
- -color => '#444444',
- },
- -confsid => {-coords => [158, 40],
- -font => 'type2',
- -text => '8G',
- -anchor => 'center',
- -color => '#444444',
- },
- -park => {-coords => [200, 40],
- -font => 'type2',
- -text => 'G23',
- -anchor => 'e',
- -color => '#444444',
- },
-
- -dest => {-coords => [10, 66],
- -font => 'type2',
- -text => 'DEST',
- -anchor => 'w',
- -color => '#555555',
- },
- -champ1 => {-type => 'rect',
- -coords => [45, 56,
- 135, 76],
- -filled => 1,
- -fillcolor => 'ch1',
- -linecolor => 'white',
- -linewidth => 0,
- },
- -bret => {-coords => [200, 66],
- -font => 'type2',
- -text => 'Bret.',
- -anchor => 'e',
- -color => '#444444',
- },
- },
- },
-
- 'zreco' => {-coords => [210, 3, 346, 82],
- -atomic => 1,
- -priority => 200,
- -texture => "stripped_texture.gif",
- -sensitive => 1,
- -tags => "edit",
- -linewidth => 2,
- -filled => 1,
- -relief => 'sunken',
- -linecolor => '#deecff',
- -fillcolor => '#d3e5ff',
- },
-
-
- },
-
- -zinfo => {-coords => [0, 86],
- -rectcoords => [0, 0, 340, 20],
- -shadowcoords => [8, 8, 348, 28],
- -shadowcolor => 'shad',
- -atomic => 1,
- -priority => 200,
- -sensitive => 1,
- -tags => "edit2",
- -linewidth => 2,
- -linecolor => '#aaccff',
- -fillcolor => 'back',
- -relief => 'roundraised',
- -fields => {-ssr => {-coords => [4, 10],
- -font => 'type3',
- -text => '7656',
- -anchor => 'w',
- -color => '#444444',
- },
- -pdep => {-coords => [47, 10],
- -font => 'type3',
- -text => 'G23',
- -anchor => 'center',
- -color => '#444444',
- },
- -qfu => {-coords => [73, 10],
- -font => 'type3',
- -text => '09R',
- -anchor => 'center',
- -color => '#444444',
- },
- -slabel => {-coords => [105, 10],
- -font => 'type3',
- -text => 'vit:',
- -anchor => 'e',
- -color => '#444444',
- },
- -speed => {-coords => [106, 10],
- -font => 'type3',
- -text => '260',
- -anchor => 'w',
- -color => '#444444',
- },
- -pper => {-coords => [142, 10],
- -font => 'type3',
- -text => 'EPL',
- -anchor => 'center',
- -color => '#444444',
- },
- -rfl => {-coords => [166, 10],
- -font => 'type3',
- -text => '210',
- -anchor => 'center',
- -color => '#444444',
- },
- -cautra => {-coords => [183, 10],
- -font => 'type3',
- -text => '8350',
- -anchor => 'w',
- -color => '#444444',
- },
- -nsect => {-coords => [219, 10],
- -font => 'type3',
- -text => 'MOD',
- -anchor => 'w',
- -color => '#444444',
- },
- -day => {-coords => [297, 10],
- -font => 'type3',
- -text => '21/05/02',
- -anchor => 'e',
- -color => '#444444',
- },
- -hour => {-coords => [332, 10],
- -font => 'type3',
- -text => '13:50',
- -anchor => 'e',
- -color => '#444444',
- },
- },
-
- },
- );
-
-# creation de la fenetre principale
-my $mw;
-$mw = MainWindow->new();
-
-# The explanation displayed when running this demo
-my $text = $mw->Text(-relief => 'sunken', -borderwidth => 2,
- -setgrid => 'true', -height =>7);
-$text->pack(qw/-expand yes -fill both/);
-
-$text->insert('0.0',
-'These fake air Traffic Control electronic strips illustrates
- the use of groups for an advanced graphic design.
-The following interactions are possible:
- "drag&drop button1" on the callsign.
- "button 1" triangle buttons on the right side of the strips
- to modify strips size
- "double click 1" on the blueish zone to fully reduce size');
-
-$mw->title('ATC strips using groups');
-
-
-#------------------------
-# creation du widget Zinc
-my $zinc = $mw->Zinc(-render => 1,
- -width => $mwidth,
- -height => $mheight,
- -borderwidth => 0,
- -lightangle => 130,
- );
-
-$zinc->pack(-fill => 'both', -expand => 1);
-
-my $texture = $zinc->Photo('background_texture.gif',
- -file => Tk->findINC('demos/zinc_data/background_texture.gif'));
-$zinc->configure(-tile => $texture) if $texture;
-
-
-
-my ($xn, $yn) = (10, 30);
-
-# test Strips
-for (my $index = 0; $index < 4 ; $index++) {
-
- &createStrip($index, $xn, $yn, \%stripstyle);
-
- $xn += 50;
- $yn += 120;
-
-}
-
-
-&initBindings('move', 'scale');
-
-
-
-
-Tk::MainLoop;
-
-#----------------------------------------------------------------------- fin de MAIN
-
-
-# Création du Strip
-sub createStrip {
- my ($index, $x, $y, $style) = @_;
-
- # initialise les gradiants
- unless (@stripGradiants) {
- my %gradiants = %{$style->{'-gradset'}};
- my ($name, $gradiant);
- while (($name, $gradiant) = each(%gradiants)) {
- # création des gradients nommés
- $zinc->gname($gradiant, $name) unless $zinc->gname($gradiant);
- # the previous test is usefull only
- # when this script is executed many time in the same process
- # (it is typically the case in zinc-demos)
-
- push(@stripGradiants, $name);
- }
- }
-
- # initialise les jeux de fontes
- unless (%stripFontset) {
- %stripFontset = %{$style->{'-fontset'}};
- }
-
- # création du groupe de base : coords
- my $g1 = $zinc->add('group', 1, -priority => 100, -tags => ["base".$index]);
- $zinc->coords($g1, [$x, $y]);
-
- # group de transfo 1 : scaling (à partir du coin haut droit)
- my $g2 = $zinc->add('group', $g1, -tags => ["scaling".$index]);
-
-
- #-------------------------------------------------------------
- # réalisation du strip lui même (papier support + ombre portée
- #-------------------------------------------------------------
-
- # params strip
- my $stripw = $style->{'-width'};
- my $striph = $style->{'-height'};
-
- # ombre portée
- $zinc->add('rectangle', $g2,
- $style->{'-shadowcoords'},
- -filled => 1,
- -linewidth => 0,
- -fillcolor => $style->{'-shadowcolor'},
- -priority => 10,
- -tags => ["shadow".$index],
- );
-
-
- # strip
- my $sstyle = $style->{'-strip'};
- my $strip = $zinc->add('rectangle', $g2,
- [0, 0, $stripw, $striph],
- -filled => 1,
- -linewidth => $sstyle->{'-linewidth'},
- -linecolor => $sstyle->{'-linecolor'},
- -fillcolor => $sstyle->{'-fillcolor'},
- -relief => $sstyle->{'-relief'},
- -priority => 20,
- -tags => ["strip".$index],
- );
-
- if ($sstyle->{'-texture'}) {
- if (!exists($textures{'-strip'})) {
- my $texture = $zinc->Photo($sstyle->{'-texture'},
- -file => Tk->findINC("demos/zinc_data/".$sstyle->{-texture}));
- $textures{'-strip'} = $texture;
- }
-
- $zinc->itemconfigure($strip, -tile => $textures{'-strip'});
- }
-
-
- #-------------------------------------------------
- # ajout de la zone des boutons (à droite du strip)
- #-------------------------------------------------
- if ($style->{'-buttons'}) {
- my $bstyle = $style->{'-buttons'};
-
- # le groupe de la zone bouton
- my $btngroup = $zinc->add('group', $g2, -priority => 40);
- $zinc->coords($btngroup, $bstyle->{'-coords'});
-
- # sa zone de clipping
- my $btnclip = $zinc->add('rectangle', $btngroup,
- $bstyle->{'-clipcoords'},
- -filled => 0,
- -visible => 0,
- );
-
- # le clipping du groupe bouton
- $zinc->itemconfigure($btngroup, -clip => $btnclip);
-
- # zone bouton
- $zinc->add('rectangle', $btngroup,
- $bstyle->{'-zone'}->{'-coords'},
- -filled => 1,
- -linewidth => $bstyle->{'-zone'}->{'-linewidth'},
- -fillcolor => $bstyle->{'-zone'}->{'-fillcolor'},
- -composescale => 0,
- -tags => ["content".$index],
- );
-
-
- my %btns = %{$bstyle->{'-btns'}};
- my ($name, $btnstyle);
- while (($name, $btnstyle) = each(%btns)) {
-# print "bouton $name $btnstyle\n";
-
- my $sgroup = $zinc->add('group', $btngroup,
- -atomic => 1,
- -sensitive => 1,
- -composescale => 0,
- -tags => [$name.$index, "content".$index],
- );
-
- $zinc->add('rectangle', $sgroup,
- $btnstyle->{'-coords'},
- -filled => 1,
- -visible => 0,
- -priority => 100,
- );
-
- $zinc->add('curve', $sgroup,
- $btnstyle->{'-arrow'},
- -closed => 1,
- -filled => 1,
- -linewidth => $btnstyle->{'-linewidth'},
- -linecolor => $btnstyle->{'-linecolor'},
- -fillcolor => $btnstyle->{'-fillcolor'},
- -priority => 50,
- );
-
- $zinc->add('text', $sgroup,
- -position => $btnstyle->{'-label'}->{'-coords'},
- -text => $btnstyle->{'-label'}->{'-text'},
- -font => $btnstyle->{'-label'}->{'-font'},
- -color => $btnstyle->{'-label'}->{'-color'},
- -anchor => $btnstyle->{'-label'}->{'-anchor'},
- -priority => 60,
- );
- }
-
- # bindings boutons Up et Down du Strip
- $zinc->bind('btnup'.$index, '<1>', \&extendedStrip);
- $zinc->bind('btndn'.$index, '<1>', \&smallStrip);
-
- }
-
- # construction du contenu du strip
- &buildContent($index, $g2, 100, $style);
-
- # et de la barre d'extension info (extended format)
- &buildExtent($index, $g2, $style->{'-zinfo'});
-
-}
-
-
-# Construction des zones internes du Strips
-sub buildContent {
- my ($index, $parent, $priority, $style) = @_;
-
- # group content
- my $g3 = $zinc->add('group', $parent, -priority => $priority);
-
- # zone de clipping
- my $clip = $zinc->add('rectangle', $g3,
- $style->{'-clipcoords'},
- -filled => 0,
- -visible => 0,
- );
-
- # clipping du groupe content
- $zinc->itemconfigure($g3, -clip => $clip);
-
- # création d'un group intermédiaire pour bloquer le scaling
- my $g4 = $zinc->add('group', $g3,
- -composescale => 0,
- -tags => ["content".$index],
- );
-
- # création des zones
- my %zones = %{$style->{'-zones'}};
- my ($name, $zonestyle);
- while (($name, $zonestyle) = each(%zones)) {
- # group de zone
- my $gz = $zinc->add('group', $g4);
-
- if ($zonestyle->{'-atomic'}) {
- $zinc->itemconfigure($gz, -atomic => 1,
- -sensitive => $zonestyle->{'-sensitive'},
- -priority => $zonestyle->{'-priority'},
- -tags => [$name.$index, $zonestyle->{'-tags'}],
- );
- }
-
- my $rectzone = $zinc->add('rectangle', $gz,
- $zonestyle->{'-coords'},
- -filled => $zonestyle->{'-filled'},
- -linewidth => $zonestyle->{'-linewidth'},
- -linecolor => $zonestyle->{'-linecolor'},
- -fillcolor => $zonestyle->{'-fillcolor'},
- -relief => $zonestyle->{'-relief'},
- -priority => 10,
- -tags => [$name.$index],
- );
-
- if ($zonestyle->{'-texture'}) {
- if (!exists($textures{$name})) {
- my $texture = $zinc->Photo($zonestyle->{'-texture'},
- -file => Tk->findINC("demos/zinc_data/".$zonestyle->{-texture}));
- $textures{$name} = $texture;
- }
-
- $zinc->itemconfigure($rectzone, -tile => $textures{$name});
- }
-
-
- my %fields;
- %fields = %{$zonestyle->{'-fields'}} if (defined $zonestyle->{'-fields'}) ;
- my ($field, $fieldstyle);
- my $fontsty = $stripFontset{'normal'};
- while ( ($field, $fieldstyle) = each(%fields) ) {
- if ($fieldstyle->{'-type'} and $fieldstyle->{'-type'} eq 'rect') {
- $zinc->add('rectangle', $gz,
- $fieldstyle->{'-coords'},
- -filled => $fieldstyle->{'-filled'},
- -fillcolor => $fieldstyle->{'-fillcolor'},
- -linewidth => $fieldstyle->{'-linewidth'},
- -linecolor => $fieldstyle->{'-linecolor'},
- -priority => 20,
- );
- } else {
-
- my $font = $fieldstyle->{'-font'};
-# print "buildContent field:$field font:$font\n";
- $zinc->add('text', $gz,
- -position => $fieldstyle->{'-coords'},
- -text => $fieldstyle->{'-text'},
- -font => $fontsty->{$font},
- -color => $fieldstyle->{'-color'},
- -anchor => $fieldstyle->{'-anchor'},
- -priority => 30,
- -tags => [$font.$index],
- );
- }
-
- }
-
- }
-}
-
-
-# Construction de la barre d'extension info du Strip
-sub buildExtent {
- my ($index, $parent, $infostyle) = @_;
-
- # group content
- my $extgroup = $zinc->add('group', $parent);
- $zinc->coords($extgroup, $infostyle->{'-coords'});
-
- $zinc->itemconfigure($extgroup,
- -atomic => $infostyle->{'-atomic'},
- -sensitive => $infostyle->{'-sensitive'},
- -priority => $infostyle->{'-priority'},
- -visible => 0,
- -tags => ["zinfo".$index, $infostyle->{'-tags'}],
- );
-
- # ombre portée
- $zinc->add('rectangle', $extgroup,
- $infostyle->{'-shadowcoords'},
- -filled => 1,
- -linewidth => 0,
- -fillcolor => $infostyle->{'-shadowcolor'},
- -priority => 10,
- -tags => ["shadow".$index],
- );
-
- my $rectzone = $zinc->add('rectangle', $extgroup,
- $infostyle->{'-rectcoords'},
- -filled => 1,
- -linewidth => $infostyle->{'-linewidth'},
- -linecolor => $infostyle->{'-linecolor'},
- -fillcolor => $infostyle->{'-fillcolor'},
- -relief => $infostyle->{'-relief'},
- -priority => 20,
- );
-
- if ($infostyle->{'-texture'}) {
- if (!exists($textures{'-zinfo'})) {
- my $texture = $zinc->Photo($infostyle->{'-texture'},
- -file => Tk->findINC("demos/zinc_data/".$infostyle->{-texture}));
- $textures{'-zinfo'} = $texture;
- }
- $zinc->itemconfigure($rectzone, -tile => $textures{'-zinfo'});
-
- }
-
- my %fields = %{$infostyle->{'-fields'}};
- my ($field, $fieldstyle);
- my $fontsty = $stripFontset{'normal'};
- while (($field, $fieldstyle) = each(%fields)) {
- if ($fieldstyle->{'-type'} and $fieldstyle->{'-type'} eq 'rect') {
- $zinc->add('rectangle', $extgroup,
- $fieldstyle->{'-coords'},
- -filled => $fieldstyle->{'-filled'},
- -fillcolor => $fieldstyle->{'-fillcolor'},
- -linewidth => $fieldstyle->{'-linewidth'},
- -linecolor => $fieldstyle->{'-linecolor'},
- -priority => 40,
- );
- } else {
-
- my $font = $fieldstyle->{'-font'};
-# print "buildContent field:$field font:$font\n";
- $zinc->add('text', $extgroup,
- -position => $fieldstyle->{'-coords'},
- -text => $fieldstyle->{'-text'},
- -font => $fontsty->{$font},
- -color => $fieldstyle->{'-color'},
- -anchor => $fieldstyle->{'-anchor'},
- -priority => 50,
- -tags => [$font.$index],
- );
- }
-
- }
-
-}
-
-# initialisation des bindings généraux dy Strip
-sub initBindings {
- my ($movetag, $scaletag) = @_;
-
- $zinc->bind($movetag, '<1>', \&catchStrip);
- $zinc->bind($movetag, '<ButtonRelease>', \&releaseStrip);
- $zinc->bind($movetag, '<B1-Motion>', \&motionStrip);
-
- $zinc->bind($scaletag, '<Double-Button-1>', \&microStrip);
-
-}
-
-# Callback CATCH de début de déplacement du Strip
-sub catchStrip {
- my $index = substr(($zinc->itemcget('current', -tags))[0], 5);
-
- my ($x, $y) = $zinc->coords("base".$index);
- my $ev = $zinc->XEvent;
- ($dx, $dy) = ($x - $ev->x, $y - $ev->y);
-
- $zinc->itemconfigure("base".$index, -priority => 200);
-
-}
-
-# Callback MOVE de fin de déplacement du Strip
-sub motionStrip {
- my $index = substr(($zinc->itemcget('current', -tags))[0], 5);
- my $ev = $zinc->XEvent;
- $zinc->coords("base".$index, [$ev->x + $dx, $ev->y + $dy]);
-
-}
-
-# Callback RELEASE de fin de déplacement du Strip
-sub releaseStrip {
- my $index = substr(($zinc->itemcget('current', -tags))[0], 5);
- $zinc->itemconfigure("base".$index, -priority => 100);
-}
-
-# Zoom Strip : normal format
-sub normalStrip {
- my $index = substr(($zinc->itemcget('current', -tags))[0], 5);
-
- $zinc->itemconfigure("input".$index, -sensitive => 1);
-
- &displayRecoZone($index, 1);
- &displayExtentZone($index, 0);
- &configButtons($index, \&extendedStrip, \&smallStrip);
- &changeStripFormat($index, 1, 1, 0, 1);
-}
-
-# Zoom Strip : small format (lignes 1 et 2)
-sub smallStrip {
- my $index = substr(($zinc->itemcget('current', -tags))[0], 5);
-
- &displayRecoZone($index, 0);
- &configButtons($index, \&normalStrip, 0);
- &changeStripFormat($index, 1, .63, 0, 1);
-}
-
-# Zoom Strip : micro format (zone ident)
-sub microStrip {
- my $index = substr(($zinc->itemcget('current', -tags))[0], 5);
-
- &configButtons($index, \&normalStrip, 0);
- &changeStripFormat($index, .28, .63, 0, 1);
-
-}
-
-# Zoom Strip : extendedFormat
-sub extendedStrip {
- my $index = substr(($zinc->itemcget('current', -tags))[0],5);
-
- $zinc->itemconfigure("input".$index, -sensitive => 0);
- $zinc->itemconfigure("base".$index, -priority => 150);
- &displayRecoZone($index, 0);
- &displayExtentZone($index, 1);
- &configButtons($index, 0, \&normalStrip);
- &changeStripFormat($index, 1.3, 1.3, 1, 1.3);
-}
-
-
-# affiche/masque la zone Reco
-sub displayRecoZone {
- my ($index, $state) = @_;
- my $priority = ($state) ? 200 : 0;
- $zinc->itemconfigure("zreco".$index, -priority => $priority);
-}
-
-
-# affiche/masque la zone Extent
-sub displayExtentZone {
- my ($index, $state) = @_;
-
- $zinc->itemconfigure("zinfo".$index,
- -visible => $state,
- -sensitive => $state);
-}
-
-# Configure affichage et callbacks des boutons du Strip
-sub configButtons {
- my ($index, $funcUp, $funcDown) = @_;
-
- # button Up
- $zinc->itemconfigure("btnup".$index, -visible => $funcUp);
- $zinc->bind('btnup'.$index, '<1>', $funcUp) if $funcUp;
-
- # button Down
- $zinc->itemconfigure("btndn".$index, -visible => $funcDown);
- $zinc->bind('btndn'.$index, '<1>', $funcDown) if $funcDown;
-
-}
-
-
-# this function has been hacked to provide the user with an animation
-# The animation is (too) simple but provide a better feedback than without
-sub changeStripFormat {
- my ($index, $xratio, $yratio, $composeflag, $fontratio) = @_;
-
- # réinitialisation du groupe scaling
- $zinc->treset("scaling".$index);
-
- # configure le blocage de transformation du format des champs
- $zinc->itemconfigure("content".$index, -composescale => $composeflag);
-
- # applique le nouveau scaling
- $scales{$index} = [1,1] unless defined $scales{$index};
- my ($oldXratio,$oldYratio) = @{$scales{$index}};
- $scales{$index}=[$xratio, $yratio];
- my $dx = ($xratio - $oldXratio) / $steps;
- my $dy = ($yratio - $oldYratio) / $steps;
- &_resize($index, $delay, $oldXratio+$dx, $oldYratio+$dy, $dx, $dy, $steps);
-}
-
-sub _resize {
- my ($index, $delay, $newXratio, $newYratio, $dx, $dy, $steps) = @_;
- $zinc->treset("scaling".$index);
- $zinc->scale("scaling".$index, $newXratio, $newYratio);
- # jeu de fontes
- &setFontes($index, $newYratio);
- $steps--;
- $zinc->after($delay, sub {&_resize ($index, $delay, $newXratio+$dx, $newYratio+$dy, $dx, $dy, $steps)})
- if $steps > 0;
-}
-
-sub getFKey {
- my ($ratio) = @_;
- my $newfkey;
-
- foreach my $param (@ratio2fontset) {
- my ($maxratio, $fkey) = @{$param};
- $newfkey = $fkey;
- if ($ratio < $maxratio) {
- return $newfkey;
- }
- }
-
- return $newfkey;
-}
-
-
-sub setFontes {
- my ($index, $ratio) = @_;
- my $newfkey = &getFKey($ratio);
-
- if (!$oldfkey or $oldfkey ne $newfkey) {
- my $fontsty = $stripFontset{$newfkey};
-# print "setFontes $oldfkey -> $newfkey\n";
- if ($fontsty) {
- foreach my $type ('callsign', 'type1', 'type2', 'type3') {
- $zinc->itemconfigure($type.$index, -font => $fontsty->{$type});
- }
- }
-
- $oldfkey = $newfkey;
- }
-}
-
diff --git a/Perl/demos/Tk/demos/zinc_lib/groups_priority.pl b/Perl/demos/Tk/demos/zinc_lib/groups_priority.pl
deleted file mode 100644
index e7f872d..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/groups_priority.pl
+++ /dev/null
@@ -1,261 +0,0 @@
-#!/usr/bin/perl -w
-# $Id$
-# This simple demo has been developped by C. Mertz <mertz@cena.fr>
-
-package groups_priority; # for avoiding symbol sharing between different demos
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-use Tk::Zinc;
-
-use strict;
-
-my $mw = MainWindow->new();
-
-# The explanation displayed when running this demo
-my $text = $mw->Text(-relief => 'sunken', -borderwidth => 2,
- -height => 12);
-$text->pack(qw/-expand yes -fill both/);
-
-$text->insert('0.0',
-'There are two groups (a red one and a green one) each containing
- 4 rectangles. Those rectangles display their current priority.
-The following operations are possible:
- "Mouse Button 1" for dragging objects.
- "Mouse Button 2" for dragging a colored group.
- "Key +" on a rectangle to raise it inside its group.
- "Key -" on a rectangle to lower it inside its group.
- "Key l" on a rectangle to lower its colored group.
- "Key r" on a rectangle to raise its colored group.
- "Key t" on a rectangle to change its group (but not its color!).
- "Key [0-9] on a rectangle to set the priority to [0-9]
-Raising or lowering an item inside a group modify its priority if necessary');
-
-# Creating the zinc widget
-my $zinc = $mw->Zinc(-width => 600, -height => 500,
- -font => "10x20", # usually fonts are sets in resources
- # but for this example it is set in the code!
- -borderwidth => 3, -relief => 'sunken',
- )->pack;
-
-#########################################################################"
-# Creating the redish group
-my $group1 = $zinc->add('group', 1, -visible => 1);
-
-my $counter=0;
-# Adding 4 rectangles with text to redish group
-foreach my $data ( [200,100, 'red'], [210,210,'red1'],
- [390,110,'red2'], [395,215,'red3'] ) {
- $counter += 2;
- my ($centerx,$centery,$color) = @{$data};
- # this small group is for merging together :
- # the rectangle and the text showing its name
- my $g = $zinc->add('group', $group1,
- -visible => 1,
- -atomic => 1,
- -sensitive => 1,
- -priority => $counter,
- );
- my $rec = $zinc->add('rectangle', $g, [$centerx-100,$centery-60,
- $centerx+100, $centery+60],
- -fillcolor => $color, -filled => 1,
- );
- my $txt = $zinc->add('text', $g,
- -position => [$centerx,$centery],
- -text => "pri=$counter",
- -anchor => 'center',
- );
- # Some bindings for dragging the rectangle or the full group
- $zinc->bind($g, '<ButtonPress-1>' => [\&press, $g, \&motion]);
- $zinc->bind($g, '<ButtonRelease-1>' => \&release);
- $zinc->bind($g, '<ButtonPress-2>' => [\&press, $g, \&groupMotion]);
- $zinc->bind($g, '<ButtonRelease-2>' => \&release);
-}
-
-#########################################################################"
-# Creating the greenish group
-my $group2 = $zinc->add('group', 1, -visible => 1);
-$counter=0;
-
-# Adding 4 rectangles with text to greenish group
-foreach my $data ( [200,300,'green1'], [210,410,'green2'],
- [390,310,'green3'], [395,415,'green4'] ) {
- $counter++;
- my ($centerx,$centery,$color) = @{$data};
- # this small group is for merging together a rectangle
- # and the text showing its priority
- my $g = $zinc->add('group', $group2,
- -atomic => 1,
- -sensitive => 1,
- -priority => $counter,
- );
- my $rec = $zinc->add('rectangle', $g, [$centerx-100,$centery-60,
- $centerx+100, $centery+60],
- -fillcolor => $color, -filled => 1,
- );
- my $txt = $zinc->add('text', $g,
- -position => [$centerx,$centery],
- -text => "pri=$counter",
- -anchor => 'center',
- );
- # Some bindings for dragging the rectangle or the full group
- $zinc->bind($g, '<ButtonPress-1>' => [\&press, $g, \&motion]);
- $zinc->bind($g, '<ButtonRelease-1>' => \&release);
- $zinc->bind($g, '<ButtonPress-2>' => [\&press, $g, \&groupMotion]);
- $zinc->bind($g, '<ButtonRelease-2>' => \&release);
-}
-
-
-#########################################################################"
-# adding the key bindings
-
-# the focus on the widget is ABSOLUTELY necessary for key bindings!
-$zinc->Tk::focus();
-
-$zinc->Tk::bind('<KeyPress-r>' => \&raiseGroup);
-$zinc->Tk::bind('<KeyPress-l>' => \&lowerGroup);
-$zinc->Tk::bind('<KeyPress-plus>' => \&raise);
-$zinc->Tk::bind('<KeyPress-KP_Add>' => \&raise);
-$zinc->Tk::bind('<KeyPress-minus>' => \&lower);
-$zinc->Tk::bind('<KeyPress-KP_Subtract>' => \&lower);
-$zinc->Tk::bind('<KeyPress-t>' => \&toggleItemGroup);
-
-my @KP_MAPPINGS = qw (Insert End Down Next Left Begin Right Home Up Prior);
-
-for my $i (0..9) {
- $zinc->Tk::bind("<KeyPress-$i>" => [\&setPriorrity, $i]);
- my $code = $KP_MAPPINGS[$i];
- $zinc->Tk::bind("<KeyPress-KP_$code>" => [\&setPriorrity, $i]);
-}
-
-# The following binding is currently not possible; only text items
-# with focus can get a KeyPress or KeyRelease event
-# $zinc->bind($g, '<KeyPress>' => [\&raise, $g]);
-
-#########################################################################"
-# Definition of all callbacks
-
-sub updateLabel {
- my ($group) = @_;
- my $priority = $zinc->itemcget($group, -priority);
- # we get the text item from this group:
- my $textitem = $zinc->find('withtype', 'text', ".$group.");
- $zinc->itemconfigure($textitem, -text => "pri=$priority");
-}
-
-sub setPriorrity {
- my ($zinc, $priority) = @_;
- my $item = $zinc->find('withtag', 'current');
- return unless $item;
- $zinc->itemconfigure ($item, -priority => $priority);
- &updateLabel($item);
-}
-
-
-# Callback to lower a small group of a rectangle and a text
-sub lower {
- my ($zinc) = @_;
- # to get the item under the cursor!
- my $item = $zinc->find('withtag', 'current');
- return unless $item;
- $zinc->lower($item);
- &updateLabel($item);
-}
-
-# Callback to raise a small group of a rectangle and a text
-sub raise {
- my ($zinc) = @_;
- # to get the item under the cursor!
- my $item = $zinc->find('withtag', 'current');
- return unless $item;
- $zinc->raise($item);
- &updateLabel($item);
-}
-
-# Callback to raise the group of groups of a rectangle and a text
-sub lowerGroup {
- my ($zinc) = @_;
- # to get the item under the cursor!
- my $item = $zinc->find('withtag', 'current');
- return unless $item;
- my $coloredGroup = $zinc->group($item);
- $zinc->lower($coloredGroup);
-}
-
-# Callback to raise the group of groups of a rectangle and a text
-sub raiseGroup {
- my ($zinc) = @_;
- # to get the item under the cursor!
- my $item = $zinc->find('withtag', 'current');
- return unless $item;
- my $coloredGroup = $zinc->group($item);
- $zinc->raise($coloredGroup);
- &updateLabel($item);
-}
-
-# Callback to change the group of groups of a rectangle and a text
-sub toggleItemGroup {
- my ($zinc) = @_;
- # to get the item under the cursor!
- my $item = $zinc->find('withtag', 'current');
- return unless $item;
- my $newgroup;
- if ($group1 == $zinc->group($item)) {
- $newgroup = $group2;
- }
- else {
- $newgroup = $group1;
- }
-
- $zinc->chggroup($item,$newgroup,1); ## the lats argument is true for mainting $item' position
- &updateLabel($item);
-}
-
-# callback for starting a drag
-my ($x_orig, $y_orig);
-sub press {
- my ($zinc, $group, $action) = @_;
- my $ev = $zinc->XEvent();
- $x_orig = $ev->x;
- $y_orig = $ev->y;
- $zinc->Tk::bind('<Motion>', [$action, $group]);
-}
-
-# Callback for moving a small group of a rectangle and a text
-sub motion {
- my ($zinc, $group) = @_;
- my $ev = $zinc->XEvent();
- my $x = $ev->x;
- my $y = $ev->y;
-
- $zinc->translate($group, $x-$x_orig, $y-$y_orig);
- $x_orig = $x;
- $y_orig = $y;
-}
-
-# Callback for moving a group of groups of a rectangle and a text
-sub groupMotion {
- my ($zinc, $group) = @_;
- my $ev = $zinc->XEvent();
- my $x = $ev->x;
- my $y = $ev->y;
-
- my $coloredGroup = $zinc->group($group);
- $zinc->translate($coloredGroup, $x-$x_orig, $y-$y_orig);
- $x_orig = $x;
- $y_orig = $y;
-}
-
-# Callback when releasing the mouse button. It removes any motion callback
-sub release {
- my ($zinc) = @_;
- $zinc->Tk::bind('<Motion>', '');
-}
-
-
-Tk::MainLoop();
-
-
-1;
diff --git a/Perl/demos/Tk/demos/zinc_lib/icon_zoom_resize.pl b/Perl/demos/Tk/demos/zinc_lib/icon_zoom_resize.pl
deleted file mode 100644
index 1274ffc..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/icon_zoom_resize.pl
+++ /dev/null
@@ -1,157 +0,0 @@
-#!/usr/bin/perl
-# $Id$
-# this simple demo has been developped by C. Mertz <mertz@cena.fr>
-
-package icon_zoom__resize; # for avoiding symbol re-use between different demos
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-use Tk::Zinc;
-use strict;
-
-
-my $defaultfont = '-adobe-helvetica-bold-r-normal--*-140-*-*-*-*-*-*';
-my $mw = MainWindow->new();
-my $text = $mw->Scrolled(qw/Text -relief sunken -borderwidth 2 -setgrid true
- -height 7 -scrollbars ''/);
-$text->pack(qw/-expand yes -fill both/);
-
-$text->insert('0.0',
- 'This demo needs openGL for rescaling/rotating the icon
- You can transform this earth gif image with your mouse:
- Drag-Button 1 for zooming the earth,
- Drag-Button 2 for rotating the earth,
- Drag-Button 3 for moving the earth,
- Shift-Drag-Button 1 for modifying the earth transparency'
- );
-
-my $zinc = $mw->Zinc(-width => 350, -height => 250,
- -render => 1,
- -font => "10x20", # usually fonts are sets in resources
- # but for this example it is set in the code!
- -borderwidth => 3, -relief => 'sunken',
- )->pack;
-
-my $earth_group = $zinc->add('group', 1, );
-
-# the following image is included in Perl/Tk distrib
-my $image = $zinc->Photo('earth.gif', -file => Tk->findINC('demos/images/earth.gif'));
-
-my $earth = $zinc->add('icon', $earth_group,
- -image => $image,
- -composescale => 1,
- -composerotation => 1,
- );
-$zinc->add('text', $earth_group,
- -position => [30,30],
-# -connecteditem => $earth,
- -text => "try to zoom/resize the earth!\nWorks even without openGL!!",
- -color => "white",
- -composescale => 1,
- -composerotation => 1,
- );
-
-$zinc->Tk::bind('<ButtonPress-1>', [\&press, \&zoom]);
-$zinc->Tk::bind('<ButtonRelease-1>', [\&release]);
-
-$zinc->Tk::bind('<ButtonPress-2>', [\&press, \&rotate]);
-$zinc->Tk::bind('<ButtonRelease-2>', [\&release]);
-
-$zinc->Tk::bind('<ButtonPress-3>', [\&press, \&motion]);
-$zinc->Tk::bind('<ButtonRelease-3>', [\&release]);
-
-
-$zinc->Tk::bind('<Shift-ButtonPress-1>', [\&press, \&modifyAlpha]);
-$zinc->Tk::bind('<Shift-ButtonRelease-1>', [\&release]);
-
-
-
-#
-# Controls for the window transform.
-#
-my ($cur_x, $cur_y, $cur_angle);
-sub press {
- my ($zinc, $action) = @_;
- my $ev = $zinc->XEvent();
- $cur_x = $ev->x;
- $cur_y = $ev->y;
- $cur_angle = atan2($cur_y, $cur_x);
- $zinc->Tk::bind('<Motion>', [$action]);
-}
-
-sub modifyAlpha {
- my ($zinc) = @_;
- my $ev = $zinc->XEvent();
- my $lx = $ev->x;
- my $xrate = $lx / $zinc->cget(-width);
-
- $xrate = 0 if $xrate < 0;
- $xrate = 1 if $xrate > 1;
-
- my $alpha = $xrate * 100;
-
- $zinc->itemconfigure($earth_group, -alpha => $alpha);
-}
-
-
-sub motion {
- my ($zinc) = @_;
- my $ev = $zinc->XEvent();
- my $lx = $ev->x;
- my $ly = $ev->y;
- my @res;
-
- @res = $zinc->transform($earth_group, [$lx, $ly, $cur_x, $cur_y]);
- $zinc->translate($earth_group, $res[0] - $res[2], $res[1] - $res[3]);
- $cur_x = $lx;
- $cur_y = $ly;
-}
-
-sub zoom {
- my ($zinc, $self) = @_;
- my $ev = $zinc->XEvent();
- my $lx = $ev->x;
- my $ly = $ev->y;
- my $maxx;
- my $maxy;
- my $sx;
- my $sy;
-
- if ($lx > $cur_x) {
- $maxx = $lx;
- } else {
- $maxx = $cur_x;
- }
- if ($ly > $cur_y) {
- $maxy = $ly
- } else {
- $maxy = $cur_y;
- }
- return if ($maxx == 0 || $maxy == 0);
- $sx = 1.0 + ($lx - $cur_x)/$maxx;
- $sy = 1.0 + ($ly - $cur_y)/$maxy;
- $cur_x = $lx;
- $cur_y = $ly;
- $zinc->scale($earth_group, $sx, $sy);
-}
-
-sub rotate {
- my ($zinc) = @_;
- my $ev = $zinc->XEvent();
- my $lx = $ev->x;
- my $ly = $ev->y;
- my $langle;
-
- $langle = atan2($ly, $lx);
- $zinc->rotate($earth_group, -($langle - $cur_angle));
- $cur_angle = $langle;
-}
-
-sub release {
- my ($zinc) = @_;
- $zinc->Tk::bind('<Motion>', '');
-}
-
-Tk::MainLoop;
diff --git a/Perl/demos/Tk/demos/zinc_lib/items.pl b/Perl/demos/Tk/demos/zinc_lib/items.pl
deleted file mode 100644
index d092924..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/items.pl
+++ /dev/null
@@ -1,187 +0,0 @@
-#!/usr/bin/perl -w
-# $Id$
-# these simple samples have been developped by C. Mertz mertz@cena.fr
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-use Tk::Zinc;
-use strict;
-
-my $defaultfont = '-adobe-helvetica-bold-r-normal--*-120-*-*-*-*-*-*';
-my $mw = MainWindow->new();
-my $zinc = $mw->Scrolled('Zinc', -width => 700, -height => 600,
- -font => '10x20', -borderwidth => 3,
- -relief => 'sunken', -scrollbars => 'se',
- -scrollregion => [-100, 0, 1000, 1000]);
-$zinc->pack(-expand => 'yes', -fill => 'both');
-
-$zinc->add('rectangle', 1, [10,10, 100, 50], -fillcolor => "green", -filled => 1,
- -linewidth => 10, -relief => "roundridge", -linecolor => "darkgreen");
-
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "A filled rectangle with a \"roundridge\" relief border of 10 pixels.",
- -anchor => 'nw',
- -position => [120, 20]);
-
-
-my $labelformat = "x82x60+0+0 x60a0^0^0 x32a0^0>1 a0a0>2>1 x32a0>3>1 a0a0^0>2";
-
-my $x=20;
-my $y=120;
-my $track=$zinc->add('track', 1, 6, # 6 is the number of fields in the flightlabel
- -labelformat => $labelformat,
- -position => [$x, $y],
- -speedvector => [40, -10],
- -speedvectormark => 1, # currently works only with openGL
- -speedvectorticks => 1, # currently works only with openGL
- );
-# moving the track, to display past positions
-foreach my $i (0..5) { $zinc->coords("$track",[$x+$i*10,$y-$i*2]); }
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "A flight track for a radar display. (A waypoint looks similar,\n".
- "but has no speedvector neither past positions)",
- -anchor => 'nw',
- -position => [200, 80],
- );
-
-$zinc->itemconfigure($track, 0,
- -filled => 0,
- -bordercolor => 'DarkGreen',
- -border => "contour",
- );
-$zinc->itemconfigure($track, 1,
- -filled => 1,
- -backcolor => 'gray60',
- -text => "AFR001");
-$zinc->itemconfigure($track, 2,
- -filled => 0,
- -backcolor => 'gray65',
- -text => "360");
-$zinc->itemconfigure($track, 3,
- -filled => 0,
- -backcolor => 'gray65',
- -text => "/");
-$zinc->itemconfigure($track, 4,
- -filled => 0,
- -backcolor => 'gray65',
- -text => "410");
-$zinc->itemconfigure($track, 5,
- -filled => 0,
- -backcolor => 'gray65',
- -text => "Beacon");
-
-
-
-
-
-$zinc->add('arc', 1, [150, 140, 450, 240], -fillcolor => "gray20",
- -filled => 0, -linewidth => 1,
- -startangle => 45, -extent => 270);
-$zinc->add('arc', 1, [260, 150, 340, 230], -fillcolor => "gray20",
- -filled => 0, -linewidth => 1,
- -startangle => 45, -extent => 270,
- -pieslice => 1, -closed => 1,
- -linestyle => 'mixed', -linewidth => 3,
- );
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "Two arcs, starting at 45° with an extent of 270°.",
- -anchor => 'nw',
- -position => [320, 180]);
-
-
-$zinc->add('curve', 1, [10, 324, 24, 300, 45, 432, 247, 356, 128, 401],
- -filled => 0, -relief => 'roundgroove',
- # -linewidth => 10, ## BUG with zinc 3.2.3g
- );
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "An open curve.",
- -anchor => 'nw',
- -position => [50, 350]);
-
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "A waypoint",
- -anchor => 'nw',
- -position => [10, 480],
- );
-my $waypoint = $zinc->add('waypoint', 1, 6, -position => [100,520],
- -labelformat => $labelformat,
- -symbol => "AtcSymbol2",
- -labeldistance => 30);
-
-foreach my $fieldId (1..5) {
- $zinc->itemconfigure($waypoint, $fieldId,
- -filled => 0,
- -bordercolor => 'DarkGreen',
- -border => "contour", # does not work with openGL (zinc-perl v3.2.3e)
- -text => "field$fieldId",
- );
-}
-
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "3 tabulars of 2 fields,\nattached together.",
- -anchor => 'nw',
- -position => [510, 380],
- );
-
-my $labelformat2 = "x72x40 x72a0^0^0 x34a0^0>1";
-
-my $tabular1 = $zinc->add('tabular', 1, 6, -position => [570,250],
- -labelformat => $labelformat2,
- );
-my $tabular2 = $zinc->add('tabular', 1, 6, -connecteditem => $tabular1,
- -labelformat => $labelformat2,
- );
-my $tabular3 = $zinc->add('tabular', 1, 6, -connecteditem => $tabular2,
- -labelformat => $labelformat2,
- );
-my $count=1;
-foreach my $tab ($tabular1, $tabular2, $tabular3) {
- $zinc->itemconfigure($tab, 1, -filled => 0,
- -bordercolor => 'DarkGreen',
- -border => "contour", -text => "tabular",
- );
- $zinc->itemconfigure($tab, 2, -filled => 0,
- -bordercolor => 'DarkGreen',
- -border => "contour", -text => "n°$count",
- );
- $count++;
-}
-
-
-$zinc->add('reticle', 1, -position => [530,550],
- -firstradius => 20, -numcircles => 6,
- -period => 2, -stepsize => 20,
- -brightlinestyle => 'dashed', -brightlinecolor => 'darkred',
- );
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "a reticle of 6 circles.",
- -anchor => 'nw',
- -position => [530, 540]);
-
-
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "maps, triangles and groups items\nare not demonstrated here.",
- -anchor => 'nw',
- -position => [10, 550]);
-
-
-
-MainLoop;
-
diff --git a/Perl/demos/Tk/demos/zinc_lib/labelformat.pl b/Perl/demos/Tk/demos/zinc_lib/labelformat.pl
deleted file mode 100644
index 465eb07..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/labelformat.pl
+++ /dev/null
@@ -1,111 +0,0 @@
-#!/usr/bin/perl -w
-# $Id$
-# This simple demo has been developped by C. Mertz <mertz@cena.fr>
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-use Tk::Zinc;
-use strict;
-
-my $mw = MainWindow->new();
-
-
-###########################################
-# Text zone
-###########################################
-
-my $text = $mw->Text(-relief => 'sunken', -borderwidth => 2,
- -height => 4);
-$text->pack(qw/-expand yes -fill both/);
-
-$text->insert('0.0',
-'This toy-appli demonstrates the use of labelformat for tabular items.
-The fieldPos (please, refer to the "labelformat type" description
-in the "Zinc reference manual") of each field as described in
-the labelformat is displayed inside the field.');
-
-
-###########################################
-# Zinc
-##########################################
-my $zinc = $mw->Zinc(-width => 600, -height => 500,
- -font => "10x20",
- -borderwidth => 3, -relief => 'sunken',
- )->pack;
-
-###########################################
-# Tabulars
-###########################################
-
-### first labelformat and tabular
-my $labelformat1 = "300x300 x100x20+0+0 x100x20+100+0 x100x20+0+20 x100x20+100+20 x100x20+50+55";
-
-my $tabular1 = $zinc->add('tabular',1, 5,
- -position => [10,10],
- -labelformat => $labelformat1,
- );
-
-&setLabelContent ($tabular1,$labelformat1);
-
-$zinc->add('text', 1, -position => [10,100], -text =>
- "All fields positions
-are given in pixels");
-
-
-### second labelformat and tabular
-my $labelformat2 = "300x300 x110x20+100+30 x80x20<0<0 x80x20<0>0 x80x20>0>0 x80x20>0<0";
-
-my $tabular2 = $zinc->add('tabular',1, 5,
- -position => [270,10],
- -labelformat => $labelformat2,
- );
-&setLabelContent ($tabular2,$labelformat2);
-
-$zinc->add('text', 1, -position => [260,100], -text =>
- "All fields positions are given
-relatively to field 0.
-They are either on the left/right
-and up/down the field 0.");
-
-
-### third labelformat and tabular
-my $labelformat3 = "400x300 x200x70+100+70 x80x26^0<0 x80x26^0>0 x80x29\$0\$0 x80x32\$0^0 x90x20\<1^1 x90x20<2\$2 x90x20^4<4 x90x20^3>3";
-
-my $tabular3 = $zinc->add('tabular',1, 9,
- -position => [150,180],
- -labelformat => $labelformat3,
- );
-&setLabelContent ($tabular3,$labelformat3);
-
-$zinc->add('text', 1, -position => [40,360], -text =>
- "Fields 1-4 are positionned relatively to field 0.
-Field 5 is positionned relatively to field 1,
-Field 6 is positionned relatively to field 2..."
-);
-
-
-### this function displays in each field, the corresponding <fieldPos>
-### part of the labelformat
-sub setLabelContent {
- my ($item,$labelformat) = @_;
-
- my @fieldsSpec = split (/ / , $labelformat);
- shift @fieldsSpec;
-
- my $i=0;
- foreach my $fieldSpec (@fieldsSpec) {
- my ($posSpec) = $fieldSpec =~ /^.\d+.\d+(.*)/ ;
-# print "$fieldSpec\t$i\t$posSpec\n";
- $zinc->itemconfigure ($item,$i,
- -text => "$i: $posSpec",
- -border => "contour",
- );
- $i++;
- }
-}
-
-
-
-MainLoop;
diff --git a/Perl/demos/Tk/demos/zinc_lib/lines.pl b/Perl/demos/Tk/demos/zinc_lib/lines.pl
deleted file mode 100644
index 5469404..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/lines.pl
+++ /dev/null
@@ -1,96 +0,0 @@
-#!/usr/bin/perl
-# $Id$
-# these simple samples have been developped by C. Mertz mertz@cena.fr
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-use Tk::Zinc;
-use strict;
-
-my $defaultfont = '-adobe-helvetica-bold-r-normal--*-120-*-*-*-*-*-*';
-my $mw = MainWindow->new();
-my $zinc = $mw->Zinc(-width => 700, -height => 600,
- -font => "10x20", # usually fonts are sets in resources
- # but for this example it is set in the code!
- -borderwidth => 3, -relief => 'sunken',
- )->pack;
-
-$zinc->add('text', 1,
- -font => $defaultfont,
- -text => "A set of lines with different styles of lines and termination\n".
- "NB: some attributes such as line styles are not necessarily\n".
- " available with an openGL rendering system" ,
- -anchor => 'nw',
- -position => [20, 20]);
-
-$zinc-> add('curve', 1, [20, 100, 320, 100]); # default options
-$zinc-> add('curve', 1, [20, 120, 320, 120],
- -linewidth => 20,
- );
-$zinc-> add('curve', 1, [20, 160, 320, 160],
- -linewidth => 20,
- -capstyle => "butt",
- );
-$zinc-> add('curve', 1, [20, 200, 320, 200],
- -linewidth => 20,
- -capstyle => "projecting",
- );
-$zinc-> add('curve', 1, [20, 240, 320, 240],
- -linewidth => 20,
- -linepattern => "AlphaStipple7",
- -linecolor => "red",
- );
-
-# right column
-$zinc-> add('curve', 1, [340, 100, 680, 100],
- -firstend => [10, 10, 10],
- -lastend => [10, 25, 45],
- );
-$zinc-> add('curve', 1, [340, 140, 680, 140],
- -linewidth => 2,
- -linestyle => 'dashed',
- );
-$zinc-> add('curve', 1, [340, 180, 680, 180],
- -linewidth => 4,
- -linestyle => 'mixed',
- );
-$zinc-> add('curve', 1, [340, 220, 680, 220],
- -linewidth => 2,
- -linestyle => 'dotted',
- );
-
-$zinc->add('curve', 1, [20, 300, 140, 360, 320, 300, 180, 260],
- -closed => 1,
- -filled => 1,
- -fillpattern => "Tk",
- -fillcolor => "grey60",
- -linecolor => "red",
- -marker => "AtcSymbol7",
- -markercolor => "blue",
-
- );
-
-
-$zinc->add('curve', 1, [340, 300, 440, 360, 620, 300, 480, 260],
- -closed => 1,
- -linewidth => 10,
- -joinstyle => "miter", #"round", # "bevel" | "miter"
- -linecolor => "red",
- );
-$zinc->add('curve', 1, [400, 300, 440, 330, 560, 300, 480, 280],
- -closed => 1,
- -linewidth => 10,
- -joinstyle => "round", # "bevel" | "miter"
- -tile => Tk::findINC("Xcamel.gif"),
- -fillcolor => "grey60",
- -filled => 1,
- -linecolor => "red",
- );
-
-# -tile => Tk::findINC("Xcamel.gif"),
-
-MainLoop;
-
-
diff --git a/Perl/demos/Tk/demos/zinc_lib/mapinfo.pl b/Perl/demos/Tk/demos/zinc_lib/mapinfo.pl
deleted file mode 100644
index f6dc46e..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/mapinfo.pl
+++ /dev/null
@@ -1,130 +0,0 @@
-#!/usr/bin/perl
-# $Id$
-# This simple demo has been developped by C. Schlienger <celine@intuilab.com>
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-use Tk::Zinc;
-use strict;
-
-
-my $defaultfont = '-adobe-helvetica-bold-r-normal--*-120-*-*-*-*-*-*';
-my $mw = MainWindow->new();
-
-###########################################
-# Text zone
-###########################################
-
-my $text = $mw->Text(-relief => 'sunken', -borderwidth => 2,
- -height => 4);
-$text->pack(qw/-expand yes -fill both/);
-
-$text->insert('0.0',
- 'This toy-appli shows zoom actions on map item.
-The following operations are possible:
- Click "-" to zoom out
- Click "+" to zoom in ' );
-
-###########################################
-# Zinc
-###########################################
-my $zinc_width=600;
-my $zinc_height=500;
-my $zinc = $mw->Zinc(-width => $zinc_width, -height => $zinc_height,
- -font => "10x20",
- -borderwidth => 3, -relief => 'sunken',
- )->pack;
-
-###########################################
-# Waypoints and sector
-###########################################
-
-my $mapinfo=$mw->mapinfo("mapinfo","create"); #creation of mapinfo
-
-#--------------------------------
-# Waypoints
-#--------------------------------
-$mw->mapinfo("mapinfo","add","symbol",200,100,0);
-$mw->mapinfo("mapinfo","add","symbol",300,150,0);
-$mw->mapinfo("mapinfo","add","symbol",400,50,0);
-$mw->mapinfo("mapinfo","add","symbol",350,450,0);
-$mw->mapinfo("mapinfo","add","symbol",300,250,0);
-$mw->mapinfo("mapinfo","add","symbol",170,240,0);
-$mw->mapinfo("mapinfo","add","symbol",550,200,0);
-
-#--------------------------------
-# Waypoints names
-#--------------------------------
-$mw->mapinfo("mapinfo","add","text","normal","simple",170,100,"DO");
-$mw->mapinfo("mapinfo","add","text","normal","simple",270,160,"RE");
-$mw->mapinfo("mapinfo","add","text","normal","simple",410,50,"MI");
-$mw->mapinfo("mapinfo","add","text","normal","simple",345,470,"FA");
-$mw->mapinfo("mapinfo","add","text","normal","simple",280,265,"SOL");
-$mw->mapinfo("mapinfo","add","text","normal","simple",150,240,"LA");
-$mw->mapinfo("mapinfo","add","text","normal","simple",555,200,"SI");
-
-#--------------------------------
-# Routes
-#--------------------------------
-
-$mw->mapinfo("mapinfo","add","line","simple",1,200,100,300,150);
-$mw->mapinfo("mapinfo","add","line","simple",1,300,150,400,50);
-$mw->mapinfo("mapinfo","add","line","simple",1,300,150,350,450);
-$mw->mapinfo("mapinfo","add","line","simple",1,300,250,170,240);
-$mw->mapinfo("mapinfo","add","line","simple",1,300,250,550,200);
-
-#--------------------------------
-# Sectors
-#---------------------------------
-$mw->mapinfo("mapinfo","add","line","simple",1,300,0,400,50);
-$mw->mapinfo("mapinfo","add","line","simple",1,400,50,500,100);
-$mw->mapinfo("mapinfo","add","line","simple",1,500,100,550,200);
-$mw->mapinfo("mapinfo","add","line","simple",1,550,200,550,400);
-$mw->mapinfo("mapinfo","add","line","simple",1,550,400,350,450);
-$mw->mapinfo("mapinfo","add","line","simple",1,350,450,170,240);
-$mw->mapinfo("mapinfo","add","line","simple",1,170,240,200,100);
-$mw->mapinfo("mapinfo","add","line","simple",1,200,100,300,0);
-
-#--------------------------------
-# Sectors
-#---------------------------------
-my $gpe = $zinc ->add('group',1);
-my $map = $zinc ->add('map',$gpe,#creation of the map object which has 'mapinfo' information
- -mapinfo=>"mapinfo",
- -symbols=>['AtcSymbol15']);
-
-
-###################################################
-# control panel
-###################################################
-my $rc = $mw->Frame()->pack();
-
-#the reference of the scale function is top-left corner of the zinc object
-#so we first translate the group to zoom in order to put its center on top-left corner
-#change the scale of the group
-#translate the group to put it back at the center of the zinc object
-
-my $minus=$rc->Button(-width => 2,
- -height => 2,
- -text => '-',
- -command=>sub{
- $zinc->translate($gpe,-$zinc_width/2,-$zinc_height/2);
- $zinc->scale($gpe,0.8,0.8);
- $zinc->translate($gpe, $zinc_width/2,$zinc_height/2);
- })->pack(-side=>'left');
-
-
-my $plus=$rc->Button(-width => 2,
- -height => 2,
- -text => '+',
- -command=>sub{
- $zinc->translate($gpe, -$zinc_width/2,-$zinc_height/2);
- $zinc->scale($gpe,1.2,1.2);
- $zinc->translate($gpe,$zinc_width/2,$zinc_height/2);
- })->pack(-side => 'right');
-
-
-
-MainLoop;
diff --git a/Perl/demos/Tk/demos/zinc_lib/path_tags.pl b/Perl/demos/Tk/demos/zinc_lib/path_tags.pl
deleted file mode 100644
index 30272d8..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/path_tags.pl
+++ /dev/null
@@ -1,357 +0,0 @@
-#!/usr/bin/perl -w
-# $Id$
-# this pathtatg demo have been developped by C. Mertz mertz@cena.fr
-# with the help of Daniel Etienne etienne@cena.fr
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-use Tk::Zinc;
-use strict;
-
-#This demo only works with Tk::Zinc > "3.2.5b";
-
-## this demo demonstrates the use of path tags to address one or more items
-## belonging to a hierarchy of groups.
-## This hierarchy is described just below, gr_xxx designates a group
-## (with a tag xxx) and i_yyy designates an non-group item (with a tag yyy).
-
-# gr_top --- gr_a --- gr_aa --- gr_aaa --- gr_aaaa --- i_aaaaa
-# | | | |-- i_aaab |-- i_aaaab
-# | | -- i_aab
-# | |-- i_ab
-# | |
-# | ---gr_ac --- i_aca
-# | |
-# |-- i_b --- i_acb
-# |
-# --- gr_c --- gr_ca --- i_caa
-# | |
-# | --- i_cab
-# |-- i_cb
-# |
-# ---gr_cc --- i_cca
-# |
-# --- i_ccb
-#the same objects are cloned and put in an other hierarchy where
-#gr_top is replaced by gr_other_top
-
-my $defaultForecolor = "grey80";
-my $selectedColor = "yellow";
-my $mw = MainWindow->new();
-
-###########################################
-# Text zone
-###########################################
-
-my $text = $mw->Text(-relief => 'sunken', -borderwidth => 2,
- -height => 5, -font => "10x20");
-$text->pack(-expand => 'yes', -fill => 'both');
-
-$text->insert('0.0',
-'This represents a group hierarchy:
- - groups are represented by a rectangle and an underlined title.
- - non-group items are represented by a text.
-Select a pathTag or a tag with one of the radio-button
-or experiment your own tags in the input field');
-
-###########################################
-# Zinc creation
-###########################################
-
-my $zinc = $mw->Zinc(-width => 850, -height => 360, -font => "10x20",
- -borderwidth => 0, -backcolor => "black",
- -forecolor => $defaultForecolor,
- )->pack;
-
-###########################################
-# Creation of a bunch of radiobutton and a text input
-###########################################
-
-my $tagsfm = $mw->Frame()->pack();
-my $pathtag;
-
-my @pl = qw/-side left -expand 1 -padx .5c -pady .2c/;
-my $left = $tagsfm->Frame->pack(@pl);
-my $middle = $tagsfm->Frame->pack(@pl);
-my $right = $tagsfm->Frame->pack(@pl);
-my $rtop = $right->Frame->pack(-side => 'top');
-my $rbottom = $right->Frame->pack(-side => 'top');
-my $rbot_left = $rbottom->Frame->pack(-side => 'left');
-my $rbot_right = $rbottom->Frame->pack(-side => 'left');
-
-my $resultfm = $mw->Frame()->pack();
-$resultfm->Label(-font => "10x20",
- -relief => 'flat',
- -text => 'explanation:',
- )->pack(-side => 'left');
-my $explan_txt = $resultfm->Label(-font => "10x20",
- -relief => 'flat',
- -width => 70,
- -height => 3.5,
- -text => '...',
- -justify => 'left',
- -wraplength => '16c',
- )->pack(-side => 'left');
-
-
-@pl = qw/-side top -pady 2 -anchor w/;
-my @tags_explan;
-@tags_explan = ("top" => "a simple tag for the top group",
- ".top" => "all items in the root group with the tag 'top'",
- ".top." => "direct children of a group in the root group with the tag 'top'",
- ".top*" => "descendance of ONE group in the root group with the tag 'top'",
- ".top*cca" => "items with a tag 'cca' in ONE direct group of root group with tag 'top'",
- ".5." => "direct content of THE group with id 5");
-while (@tags_explan) {
- my $tag = shift @tags_explan;
- my $explan = shift @tags_explan;
- $left->Radiobutton(-text => $tag,
- -font => "10x20",
- -command => sub { &displayPathtag ($explan)},
- -variable => \$pathtag,
- -relief => 'flat',
- -value => $tag,
- )->pack(@pl);
-}
-@tags_explan = (".top*aa" => "items with a tag 'aa' in a direct group of root group with tag 'top'",
- ".top*aa." => "direct children of ONE group with a tag 'aa', descending from a direct group of root group with tag 'top'",
- ".top*aa*" => "descendance of ONE group with a tag 'aa', descending from a direct group of root group with tag 'top'",
- ".top.a" => "items with a tag 'a' in a direct group of root group with tag 'top'",
- ".top.a." => "direct children of ONE group with a tag 'a' in a direct group of root group with tag 'top'",
- ".5*" => "descendance of THE group with id 5",
- );
-while (@tags_explan) {
- my $tag = shift @tags_explan;
- my $explan = shift @tags_explan;
- $middle->Radiobutton(-text => $tag,
- -font => "10x20",
- -command => sub { &displayPathtag ($explan)},
- -variable => \$pathtag,
- -relief => 'flat',
- -value => $tag,
- )->pack(@pl);
-}
-
-
-$rtop->Label(-font => "10x20",
- -relief => 'flat',
- -text => 'your own tag :',
- )->pack(-side => 'left');
-$rtop->Entry(-font => "10x20", -width => 15)
- ->pack(-side => 'left')->bind('<Key-Return>', sub {$pathtag = $_[0]->get();
- &displayPathtag("sorry, I am not smart enough to explain your pathTag ;-)")});
-
-
-@tags_explan = (".top*aa*aaa" => "all items with a tag 'aaa' descending from ONE group with a tag 'aa' descending from ONE group with a tag 'top' child of the root group",
- ".top*aa*aaa." => "children of ONE group with a tag 'aaa' descending from ONE group with a tag 'aa' descending from ONE group with a tag 'top' child of the root group",
- ".top*aa*aaa*" => "descendance of ONE group with a tag 'aaa' descending from ONE group with a tag 'aa' descending from ONE group with a tag 'top' child of the root group",
- ".other_top*aa*" => "descendance of ONE group with a tag 'aa' descending from ONE group with a tag 'other_top' child of the root group",
- ".5*ca*" => "descendance of ONE group with a tag 'ca' descending from THE group with id 5",
- );
-while (@tags_explan) {
- my $tag = shift @tags_explan;
- my $explan = shift @tags_explan;
- $rbot_left->Radiobutton(-text => $tag,
- -font => "10x20",
- -command => sub { &displayPathtag ($explan)},
- -variable => \$pathtag,
- -relief => 'flat',
- -value => $tag,
- )->pack(@pl);
-}
-
-@tags_explan = ("*aa*aaaa" => "all items with a tag 'aaaa' descending from a group with a tag 'aa'",
- "*aaa" => "all items with a tag 'aaa'",
- "aa || ca" => "items with tag 'aa' or tag 'ca'",
- "none" => "no items, as none has the tag 'none'",
- "all" => "all items",
- );
-while (@tags_explan) {
- my $tag = shift @tags_explan;
- my $explan = shift @tags_explan;
- $rbot_right->Radiobutton(-text => $tag,
- -font => "10x20",
- -command => sub { &displayPathtag ($explan)},
- -command => \&displayPathtag,
- -variable => \$pathtag,
- -relief => 'flat',
- -value => $tag,
- )->pack(@pl);
-}
-
-# creating the item hierarchy
-$zinc ->add('group', 1, -tags => ['top']);
-&createSubHierarchy ('top');
-
-# creating a parallel hierarchy
-$zinc ->add('group', 1, -tags => ['other_top']);
-&createSubHierarchy ('other_top');
-
-### Here we create the genuine hierarchy of groups and items
-### Later we will create graphical objects to display groups
-sub createSubHierarchy {
- my ($gr) = @_;
- $zinc->add('group', $gr, -tags => ['a']);
- $zinc->add('text', $gr, -tags => ['b', 'text'], -text => 'b',
- -position => [270,150]);
- $zinc->add('group', $gr, -tags => ['c']);
-
- $zinc->add('group', 'a', -tags => ['aa']);
- $zinc->add('text', 'a', -tags => ['ab', 'text'], -text => 'ab'
- , -position => [60,220]);
- $zinc->add('group', 'a', -tags => ['ac']);
-
- $zinc->add('group', 'aa', -tags => ['aaa']);
- $zinc->add('text', 'aa', -tags => ['aab', 'text'], -text => 'aab',
- -position => [90,190]);
- $zinc->add('group', 'aaa', -tags => ['aaaa']);
- $zinc->add('text', 'aaaa', -tags => ['aaaaa', 'text'], -text => 'aaaaa',
- -position => [150,110]);
- $zinc->add('text', 'aaaa', -tags => ['aaaab', 'text'], -text => 'aaaab',
- -position => [150,130]);
- $zinc->add('text', 'aaa', -tags => ['aaab', 'text'], -text => 'aaab',
- -position => [120,160]);
-
- $zinc->add('text', 'ac', -tags => ['aca'], -text => 'aca',
- -position => [90,260]);
- $zinc->add('text', 'ac', -tags => ['acb', 'text'], -text => 'acb',
- -position => [90,290]);
-
- $zinc->add('group', 'c', -tags => ['ca']);
- $zinc->add('text', 'c', -tags => ['cb', 'text'], -text => 'cb',
- -position => [330,160]);
- $zinc->add('group', 'c', -tags => ['cc']);
-
- $zinc->add('text', 'ca', -tags => ['caa', 'text'], -text => 'caa',
- -position => [360,110]);
- $zinc->add('text', 'ca', -tags => ['cab', 'text'], -text => 'cab',
- -position => [360,130]);
-
- $zinc->add('text', 'cc', -tags => ['cca', 'text'], -text => 'cca',
- -position => [360,200]);
- $zinc->add('text', 'cc', -tags => ['ccb', 'text'], -text => 'ccb',
- -position => [360,220]);
-}
-
-## modifying the priority so that all rectangles and text will be visible
-map { $_, $zinc->itemconfigure($_,-priority => 20)} ($zinc->find('withtype', 'text', ".top*"));
-map { $_, $zinc->itemconfigure($_,-priority => 20)} ($zinc->find('withtype', 'text', ".other_top*"));
-map { $_, $zinc->itemconfigure($_,-priority => 20)} ($zinc->find('withtype', 'group', ".top*"));
-map { $_, $zinc->itemconfigure($_,-priority => 20)} ($zinc->find('withtype', 'group', ".other_top*"));
-
-# converts a list of items ids in a list of sorted tags (the first tag of each item)
-sub items2tags {
- my @items = @_;
- my @selected_tags;
- foreach my $item (@items) {
- my @tags = $zinc->itemcget ($item, -tags);
- next if $tags[0] =~ /frame|title/ ; # to remove group titles frame
- push @selected_tags, $tags[0];
- }
- return sort @selected_tags;
-}
-
-### drawing :
-#### a rectangle item for showing the bounding box of each group,
-### a text item for the group name (i.e. its first tag)
-
-## backgrounds used to fill rectangles representing groups
-my @backgrounds = qw(grey25 grey35 grey43 grey50 grey55);
-
-sub drawHierarchy {
- my ($group,$level) = @_;
- my @tags = $zinc->gettags($group);
-# print "level=$level (", $tags[0],")\n";
- foreach my $g ($zinc->find('withtype', 'group', ".$group.")) {
- &drawHierarchy ($g,$level+1);
- }
- my ($x,$y,$x2,$y2) = $zinc->bbox($group);
- $zinc->add('text',$group, -position => [$x-5,$y-4],
- -text => $tags[0], -anchor => "w", -alignment => "left",
- -underlined => 1,
- -priority => 20,
- -tags => ["title_".$tags[0], 'group_title'],
- );
- ($x,$y,$x2,$y2) = $zinc->bbox($group);
- if (defined $x) {
- my $background = $backgrounds[$level];
- $zinc->add('rectangle', $group, [$x+0,$y+5,$x2+5,$y2+2],
- -filled => 1,
- -fillcolor => $background,
- -priority => $level,
- -tags => ["frame_".$tags[0], 'group_frame'],
- );
- } else {
- print "undefined bbox for $group : @tags\n";
- }
-}
-
-### this sub extracts out of groups both text and frame representing
-### each group. This is necessary to avoid unexpected selection of
-### rectangles and titles inside groups
-sub extractTextAndFrames {
- foreach my $group_title ($zinc->find('withtag', 'group_title || group_frame')) {
- my @ancestors = $zinc->find('ancestor',$group_title);
-# print "$group_title, @ancestors\n";
- my $grandFather = $ancestors[1];
- $zinc->chggroup($group_title,$grandFather,1);
- }
-}
-
-## this sub modifies the color/line color of texts and rectangles
-## representing selected items.
-sub displayPathtag {
-# print "var=@_ $pathtag\n";
- my $explanation = shift;
- my @selected = $zinc->find('withtag', $pathtag);
- my @tags = &items2tags(@selected);
-# print "selected: @tags\n";
- $explan_txt->configure(-text => $explanation ? "$explanation\n" : "");
-
- ## unselecting all items
- foreach my $item ($zinc->find('withtype', 'text')) {
- $zinc->itemconfigure($item, -color => $defaultForecolor);
- }
- foreach my $item ($zinc->find('withtype', 'rectangle')) {
- $zinc->itemconfigure($item, -linecolor => $defaultForecolor);
- }
-
- ## highlighting selected items
- foreach my $item (@selected) {
- my $type = $zinc->type($item);
-# print $item, " ", $zinc->type($item), " ", join (",",$zinc->gettags($item)), "\n";
- if ($type eq 'text') {
- $zinc->itemconfigure($item, -color => $selectedColor);
- } elsif ($type eq 'rectangle') {
- $zinc->itemconfigure($item, -linecolor => $selectedColor);
- } elsif ($type eq 'group') {
- my $tag = ($zinc->gettags($item))[0];
- ## as there is 2 // hierachy, we must refine the tag used
- ## to restrict to the proper hierarchy
- ## NB: this is due to differences between the group hierarchy
- ## and the graphical object hierarchy used for this demo
- if ($zinc->find('ancestors',$item,'top')) {
- $zinc->itemconfigure(".top*frame_$tag", -linecolor => $selectedColor);
- $zinc->itemconfigure(".top*title_$tag", -color => $selectedColor);
- } elsif ($zinc->find('ancestors',$item,'other_top')) {
- $zinc->itemconfigure(".other_top*frame_$tag", -linecolor => $selectedColor);
- $zinc->itemconfigure(".other_top*title_$tag", -color => $selectedColor);
- } else {
- $zinc->itemconfigure("frame_$tag", -linecolor => $selectedColor);
- $zinc->itemconfigure("title_$tag", -color => $selectedColor);
- }
- }
- }
-}
-
-&drawHierarchy('top',0);
-&drawHierarchy('other_top',0);
-$zinc->translate('other_top', 400,0);
-&extractTextAndFrames;
-
-
-
-MainLoop;
-
diff --git a/Perl/demos/Tk/demos/zinc_lib/rotation.pl b/Perl/demos/Tk/demos/zinc_lib/rotation.pl
deleted file mode 100644
index c5549bf..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/rotation.pl
+++ /dev/null
@@ -1,124 +0,0 @@
-#!/usr/bin/perl
-# $Id$
-# This simple demo has been developped by C. Schlienger <celine@intuilab.com>
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-
-use Tk;
-use Tk::Zinc;
-use strict;
-use constant;
-
-my constant $PI=3.1416;
-
-my $defaultfont = '-adobe-helvetica-bold-r-normal--*-120-*-*-*-*-*-*';
-my $mw = MainWindow->new();
-
-
-###########################################
-# Text zone
-###########################################
-
-my $text = $mw->Text(-relief => 'sunken', -borderwidth => 2, -height => 4);
-$text->pack(qw/-expand yes -fill both/);
-
-$text->insert('0.0',
- 'This toy-appli shows rotations on waypoint items.
-The following operations are possible:
- Click "<-" for negative rotation
- Click "->" for positive rotation' );
-
-
-###########################################
-# Zinc
-###########################################
-my $zinc_width=600;
-my $zinc_height=500;
-my $zinc = $mw->Zinc(-width => $zinc_width, -height => $zinc_height,
- -font => "10x20",
- -borderwidth => 3, -relief => 'sunken',
- )->pack;
-
-###########################################
-# Waypoints
-###########################################
-
-my $wp_group = $zinc->add('group', 1, -visible => 1);
-
-my $p1=[200, 200];
-my $wp1 = $zinc->add('waypoint',$wp_group, 1,
- -position => $p1,
- -connectioncolor => 'green',
- -symbolcolor => 'blue',
- -labelformat => 'x20x18+0+0',
- -leaderwidth=>'0',
- -labeldx=>'-20'
- );
-$zinc->itemconfigure($wp1, 0,
- -text => "DO",
- );
-
-my $p2=[300, 300];
-my $wp2 = $zinc->add('waypoint',$wp_group, 1,
- -position => $p2,
- -connecteditem => $wp1,
- -connectioncolor => 'blue',
- -symbolcolor => 'blue',
- -labelformat => 'x20x18+0+0',
- -leaderwidth=>'0',
- -labeldx=>'-20',
- #-labeldy=>'30'
- );
-
-$zinc->itemconfigure($wp2, 0,
- -text => "RE",
- );
-
-my $p3=[400, 150];
-my $wp3 = $zinc->add('waypoint', $wp_group, 2,
- -position => $p3,
- -connecteditem => $wp2,
- -connectioncolor => 'blue',
- -symbolcolor => 'blue',
- -labelformat => 'x20x18+0+0',
- -leaderwidth=>'0',
- -labeldx=>'20',
- -labeldy=>'+10'
- );
-$zinc->itemconfigure($wp3, 0,
- -text => "MI",
- );
-
-###################################################
-# control panel
-###################################################
-my $rc = $mw->Frame()->pack();
-
-my $left=$rc->Button(-width => 2,
- -height => 2,
- -text => '<-',
- -command=>sub{
- #--------------------------------
- # Negative rotation
- #--------------------------------
- my @centre=$zinc->coords("$wp2"); #the center of the rotation is $wp2
- $zinc->rotate("$wp_group",-$PI/6,$centre[0],$centre[1]);
- })->pack(-side => 'left');
-
-my $right=$rc->Button(-width => 2,
- -height => 2,
- -text => '->',
- -command=>sub{
- #--------------------------------
- # Positive rotation
- #--------------------------------
- my @centre=$zinc->coords("$wp2");#the center of the rotation is $wp2
- $zinc->rotate("$wp_group",+$PI/6,$centre[0],$centre[1]);
- })->pack(-side=>'right');
-
-
-
-
-MainLoop;
diff --git a/Perl/demos/Tk/demos/zinc_lib/simple_interaction_track.pl b/Perl/demos/Tk/demos/zinc_lib/simple_interaction_track.pl
deleted file mode 100644
index 2ceb925..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/simple_interaction_track.pl
+++ /dev/null
@@ -1,269 +0,0 @@
-#!/usr/bin/perl
-# $Id$
-# This simple demo has been developped by C. Schlienger <celine@intuilab.com>
-
-package simple_interaction_track; # for avoiding symbol collision between different demos
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-
-use Tk;
-use Tk::Zinc;
-use strict;
-
-my $mw = MainWindow->new();
-
-
-
-###########################################
-# Zinc
-###########################################
-my $zinc_width=600;
-my $zinc_height=500;
-my $zinc = $mw->Zinc(-width => $zinc_width, -height => $zinc_height,
- -font => "10x20",
- -borderwidth => 3, -relief => 'sunken',
- )->pack;
-
-# The explanation displayed when running this demo
-$zinc->add('text', 1,
- -position=> [10,10],
- -text => 'This toy-appli shows some interactions on different parts
-of a flight track item. The following operations are possible:
- - Drag Button 1 on the track to move it.
- Please Note the position history (past positions)
- - Enter/Leave flight label fields
- - Enter/Leave the speedvector, symbol (i.e. current position),
- label, or leader',
- -font => "9x15",
- );
-
-###########################################
-# Track
-###########################################
-
-#the label format (6 formats for 6 fields)#
-my $labelformat = "x80x60+0+0 x60a0^0^0 x30a0^0>1 a0a0>2>1 x30a0>3>1 a0a0^0>2";
-
-#the track#
-my $x=250;
-my $y=200;
-my $track=$zinc->add('track', 1, 6, # 6 is the number of field in the flightlabel
- -labelformat => $labelformat,
- -position => [$x, $y],#position of the marker
- -speedvector => [30, -15],#ccords of the speed vector
- -markersize => 10,
- );
-# moving the track, to display past positions
-foreach my $i (0..5) { $zinc->coords($track,[$x+$i*10,$y-$i*5]); }
-
-#fields of the label#
-$zinc->itemconfigure($track, 0,#configuration of field 0 of the label
- -filled => 0,
- -bordercolor => 'DarkGreen',
- -border => "contour",
- );
-$zinc->itemconfigure($track, 1,
- -filled => 1,
- -backcolor => 'gray60',
- -text => "AFR6128");
-$zinc->itemconfigure($track, 2,
- -filled => 0,
- -backcolor => 'gray65',
- -text => "390");
-$zinc->itemconfigure($track, 3,
- -filled => 0,
- -backcolor => 'gray65',
- -text => "/");
-$zinc->itemconfigure($track, 4,
- -filled => 0,
- -backcolor => 'gray65',
- -text => "350");
-$zinc->itemconfigure($track, 5,
- -filled => 0,
- -backcolor => 'gray65',
- -text => "TUR");
-
-
-
-###########################################
-# Events on the track
-###########################################
-#---------------------------------------------
-# Enter/Leave a field of the label of the track
-#---------------------------------------------
-
-foreach my $field (0..5) {
- #Entering the field $field higlights it#
- $zinc->bind("$track:$field",
- '<Enter>',
- sub {
- if ($field==0){
- higlight_label_on();
-# print "CP=", $zinc->currentpart, "\n";
- }
- else{
- highlight_fields_on($field);
-# print "CP=", $zinc->currentpart, "\n";
- }
-
- });
- #Leaving the field cancels the highlight of $field#
- $zinc->bind("$track:$field",
- '<Leave>',
- sub {
- if($field==0){
- higlight_label_off();
- }
- else{
- if ($field==1){
- highlight_field1_off();
- }
- else{
- highlight_other_fields_off($field);
- }
- }
- });
-}
-
-#fonction#
-sub higlight_label_on{
- $zinc->itemconfigure('current', 0,
- -filled => 0,
- -bordercolor => 'red',
- -border => "contour",
- );
-
-}
-sub higlight_label_off{
- $zinc->itemconfigure('current', 0,
- -filled => 0,
- -bordercolor => 'DarkGreen',
- -border => "contour",
- );
-
-
-}
-
-sub highlight_fields_on{
- my $field=$_[0];
- $zinc->itemconfigure('current', $field,
- -border => 'contour',
- -filled => 1,
- -color => 'white'
- );
-
-}
-sub highlight_field1_off{
- $zinc->itemconfigure('current', 1,
- -border => '',
- -filled => 1,
- -color => 'black',
- -backcolor => 'gray60'
- );
-
-}
-
-sub highlight_other_fields_off{
- my $field=$_[0];
- $zinc->itemconfigure('current', $field,
- -border => '',
- -filled => 0,
- -color => 'black',
- -backcolor => 'gray65'
- );
-}
-#---------------------------------------------
-# Enter/Leave other parts of the track
-#---------------------------------------------
-$zinc->bind("$track:position",
- '<Enter>',
- sub { $zinc->itemconfigure($track,
- -symbolcolor=>"red",
- );
-# print "CP=", $zinc->currentpart, "\n";
- });
-$zinc->bind("$track:position",
- '<Leave>',
- sub { $zinc->itemconfigure($track,
- -symbolcolor=>"black",
- );
- });
-
-$zinc->bind("$track:speedvector",
- '<Enter>',
- sub { $zinc->itemconfigure($track,
- -speedvectorcolor=>"red",
- );
- });
-$zinc->bind("$track:speedvector", '<Leave>',
- sub { $zinc->itemconfigure($track,
- -speedvectorcolor=>"black",
- );
- });
-
-$zinc->bind("$track:leader", '<Enter>',
- sub { $zinc->itemconfigure($track,
- -leadercolor=>"red",
- );
- });
-
-$zinc->bind("$track:leader", '<Leave>',
- sub { $zinc->itemconfigure($track,
- -leadercolor=>"black",
- );
- });
-
-#---------------------------------------------
-# Drag and drop the track
-#---------------------------------------------
-#Binding to ButtonPress event -> "move_on" state#
-$zinc -> bind($track,'<ButtonPress-1>'=>[ sub { &select_color_on(); #change the color
- &move_on($_[1],$_[2]); #"move_on" state
- }, Tk::Ev('x'),Tk::Ev('y') ]);
-
-#Binding to ButtonRelease event -> "move_off" state#
-$zinc -> bind($track,'<ButtonRelease-1>'=>sub{&select_color_off(); #change the color
- &move_off();}); #"move_off" state
-
-#"move_on" state#
-sub move_on{
- my ($xi,$yi)=@_;
- #Binding to Motion event -> move the track#
- $zinc -> bind($track,'<Motion>'=>
- [sub{move($xi,$yi,$_[1],$_[2]); #move the track
- $xi=$_[1];
- $yi=$_[2];
- },Tk::Ev('x'),Tk::Ev('y')]);
-}
-
-#"move_off" state#
-sub move_off{
- #Motion event not allowed on track
- $zinc -> bind($track,'<Motion>'=>"");
-}
-
-#move the track#
-sub move{
- my ($xi,$yi,$x,$y)=@_;
- select_color_on();
- my @coords=$zinc->coords($track);
- $zinc->coords($track,[$coords[0]+$x-$xi,$coords[1]+$y-$yi]);
-}
-
-
-sub select_color_on{
- $zinc->itemconfigure($track,
- -speedvectorcolor=>"white",
- -markercolor=>"white",
- -leadercolor=>"white" );
-}
-
-sub select_color_off{
- $zinc->itemconfigure($track,
- -speedvectorcolor=>"black",
- -markercolor=>"black",
- -leadercolor=>"black" );
-}
- Tk::MainLoop;
diff --git a/Perl/demos/Tk/demos/zinc_lib/simpleradar.pl b/Perl/demos/Tk/demos/zinc_lib/simpleradar.pl
deleted file mode 100644
index 12c45a9..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/simpleradar.pl
+++ /dev/null
@@ -1,489 +0,0 @@
-#!/usr/bin/perl -w
-# $Id$
-# This simple radar has been initially developped by P. Lecoanet <lecoanet@cena.fr>
-# It has been adapted by C. Mertz <mertz@cena.fr> for demo purpose.
-
-package simpleradar; # for avoiding symbol collision between different demos
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-
-use Tk;
-use Tk::Zinc;
-
-use strict;
-
-# to find the SimpleRadarControls module
-require Tk->findINC('demos/zinc_pm/SimpleRadarControls.pm');
-
-my $mw = MainWindow->new();
-
-my $text = $mw->Text(-relief => 'sunken', -borderwidth => 2,
- -height => 11);
-$text->pack(qw/-expand yes -fill both/);
-
-$text->insert('0.0',
- 'This a very simple radar display, where you can see flight tracks,
- a so-called ministrip (green) and and extend flight label (tan background).
- The following operations are possible:
- Shift-Button 1 for using a squarre lasso (result in the terminal).
- Click Button 2 for identifiying the closest item (result in the terminal).
- Button 3 for dragging most items, but not the ministrip (not in the same group).
- Shift-Button 3 for zooming independently on X and Y axis.
- Ctrl-Button 3 for rotationg graphic objects.
- Enter/Leave in flight label fields, speed vector, position and leader,
- and in the ministrip fields.
- Click Button 1 on flight track to display a route.');
-
-
-
-###################################################
-# creation zinc
-###################################################
-my $top = 1;
-my $scale = 1.0;
-my $center_x = 0.0;
-my $center_y = 0.0;
-my $zinc_width = 800;
-my $zinc_height = 500;
-my $delay = 2000;
-my $rate = 0.3;
-my %tracks = ();
-
-my $pause = 0; # if true the flight are no more moving
-my $zinc = $mw->Zinc(-backcolor => 'gray65',
- -relief => 'sunken',
- -font => "10x20");
-$zinc->pack(-expand => 1, -fill => 'both');
-$zinc->configure(-width => $zinc_width, -height => $zinc_height);
-#$radar = $top;
-my $radar = $zinc->add('group', $top, -tags => ['controls', 'radar']);
-$zinc->configure(-overlapmanager => $radar);
-
-
-###################################################
-# creation panneau controle
-###################################################
-my $rc = $mw->Frame()->pack();
-$rc->Button(-text => 'Up',
- -command => sub { $center_y -= 30.0;
- update_transform($zinc); })->grid(-row => 0,
- -column => 2,
- -sticky, 'ew');
-$rc->Button(-text => 'Down',
- -command => sub { $center_y += 30.0;
- update_transform($zinc); })->grid(-row => 2,
- -column => 2,
- -sticky, 'ew');
-$rc->Button(-text => 'Left',
- -command => sub { $center_x += 30.0;
- update_transform($zinc); })->grid(-row => 1,
- -column => 1);
-$rc->Button(-text => 'Right',
- -command => sub { $center_x -= 30.0;
- update_transform($zinc); })->grid(-row => 1,
- -column => 3);
-$rc->Button(-text => 'Expand',
- -command => sub { $scale *= 1.1;
- update_transform($zinc); })->grid(-row => 1,
- -column => 4);
-$rc->Button(-text => 'Shrink',
- -command => sub { $scale *= 0.9;
- update_transform($zinc); })->grid(-row => 1,
- -column => 0);
-$rc->Button(-text => 'Reset',
- -command => sub { $scale = 1.0;
- $center_x = $center_y = 0.0;
- update_transform($zinc); })->grid(-row => 1,
- -column => 2,
- -sticky, 'ew');
-
-$rc->Button(-text => 'Pause',
- -command => sub { $pause = ! $pause;
- })->grid(-row => 0,
- -column => 6);
-
-###################################################
-# Code de reconfiguration lors d'un
-# redimensionnement.
-###################################################
-$zinc->Tk::bind('<Configure>', [\&resize]);
-
-sub resize {
- my ($zinc) = @_;
- my $ev = $zinc->XEvent();
- my $width = $ev->w;
- my $height = $ev->h;
- my $bw = $zinc->cget(-borderwidth);
- $zinc_width = $width - 2*$bw;
- $zinc_height = $height - 2*$bw;
- update_transform($zinc);
-}
-
-sub update_transform {
- my ($zinc) = @_;
- $zinc->treset($top);
- $zinc->translate($top, -$center_x, -$center_y);
- $zinc->scale($top, $scale, $scale);
- $zinc->scale($top, 1, -1);
- $zinc->translate($top, $zinc_width/2, $zinc_height/2);
-}
-
-
-###################################################
-# Creation de pistes.
-###################################################
-my $one_of_track_item;
-sub create_tracks {
- my $i = 20;
- my $j;
- my $track;
- my $x;
- my $y;
- my $w = $zinc_width / $scale;
- my $h = $zinc_height / $scale;
- my $d;
- my $item;
-
- for ( ; $i > 0; $i--) {
- $track = {};
- $track->{'item'} = $item = $zinc->add('track', $radar, 6);
- $one_of_track_item = $item;
- $tracks{$item} = $track;
- $track->{'x'} = rand($w) - $w/2 + $center_x;
- $track->{'y'} = rand($h) - $h/2 + $center_y;
- $d = (rand() > 0.5) ? 1 : -1;
- $track->{'vx'} = (8.0 + rand(10.0)) * $d;
- $d = (rand() > 0.5) ? 1 : -1;
- $track->{'vy'} = (8.0 + rand(10.0)) * $d;
- $zinc->itemconfigure($item,
- -position => [$track->{'x'}, $track->{'y'}],
- -speedvector => [$track->{'vx'}, $track->{'vy'}],
- -speedvectorsensitive => 1,
- -labeldistance => 30,
- -markersize => 20,
- -historycolor => 'gray30',
- -filledhistory => 0,
- -circlehistory => 1,
- -labelformat => "x80x60+0+0 x63a0^0^0 x33a0^0>1 a0a0>2>1 x33a0>3>1 a0a0^0>2");
- $zinc->itemconfigure($item, 0,
- -filled => 0,
- -backcolor => 'gray60',
-# -border => "contour",
- -sensitive => 1
- );
- $zinc->itemconfigure($item, 1,
- -filled => 1,
- -backcolor => 'gray55',
- -text => sprintf ("AFR%03i",$i));
- $zinc->itemconfigure($item, 2,
- -filled => 0,
- -backcolor => 'gray65',
- -text => "360");
- $zinc->itemconfigure($item, 3,
- -filled => 0,
- -backcolor => 'gray65',
- -text => "/");
- $zinc->itemconfigure($item, 4,
- -filled => 0,
- -backcolor => 'gray65',
- -text => "410");
- $zinc->itemconfigure($item, 5,
- -filled => 0,
- -backcolor => 'gray65',
- -text => "Balise");
- my $b_on = sub { $zinc->itemconfigure('current', $zinc->currentpart(),
- -border => 'contour')};
- my $b_off = sub { $zinc->itemconfigure('current', $zinc->currentpart(),
- -border => 'noborder')};
- my $tog_b = sub { my $current = $zinc->find('withtag', 'current');
- my $curpart = $zinc->currentpart();
- if ($curpart =~ '[0-9]+') {
- my $on_off = $zinc->itemcget($current, $curpart, -sensitive);
- $zinc->itemconfigure($current, $curpart,
- -sensitive => !$on_off);
- }
- };
- for ($j = 0; $j < 6; $j++) {
- $zinc->bind($item.":$j", '<Enter>', $b_on);
- $zinc->bind($item.":$j", '<Leave>', $b_off);
- $zinc->bind($item, '<1>', $tog_b);
- $zinc->bind($item, '<Shift-1>', sub {});
- }
- $zinc->bind($item, '<Enter>',
- sub {$zinc->itemconfigure('current',
- -historycolor => 'red3',
- -symbolcolor => 'red3',
- -markercolor => 'red3',
- -leaderwidth => 2,
- -leadercolor => 'red3',
- -speedvectorwidth => 2,
- -speedvectorcolor => 'red3')});
- $zinc->bind($item, '<Leave>',
- sub {$zinc->itemconfigure('current',
- -historycolor => 'black',
- -symbolcolor => 'black',
- -markercolor => 'black',
- -leaderwidth => 1,
- -leadercolor => 'black',
- -speedvectorwidth => 1,
- -speedvectorcolor => 'black')});
- $zinc->bind($item.':position', '<1>', [\&create_route]);
- $zinc->bind($item.':position', '<Shift-1>', sub { });
- $track->{'route'} = 0;
- }
-}
-
-create_tracks();
-
-###################################################
-# creation way point
-###################################################
-sub create_route {
- my ($zinc) = @_;
- my $wp;
- my $connected;
- my $x;
- my $y;
- my $i = 4;
- my $track = $tracks{$zinc->find('withtag', 'current')};
-
- if ($track->{'route'} == 0) {
- $x = $track->{'x'} + 8.0 * $track->{'vx'};
- $y = $track->{'y'} + 8.0 * $track->{'vy'};
- $connected = $track->{'item'};
- for ( ; $i > 0; $i--) {
- $wp = $zinc->add('waypoint', 'radar', 2,
- -position => [$x, $y],
- -connecteditem => $connected,
- -connectioncolor => 'green',
- -symbolcolor => 'green',
- -labelformat => 'x20x18+0+0');
- $zinc->lower($wp, $connected);
- $zinc->bind($wp.':0', '<Enter>',
- sub {$zinc->itemconfigure('current', 0, -border => 'contour')});
- $zinc->bind($wp.':position', '<Enter>',
- sub {$zinc->itemconfigure('current', -symbolcolor => 'red')});
- $zinc->bind($wp.':leader', '<Enter>',
- sub {$zinc->itemconfigure('current', -leadercolor => 'red')});
- $zinc->bind($wp.':connection', '<Enter>',
- sub {$zinc->itemconfigure('current', -connectioncolor => 'red')});
- $zinc->bind($wp.':0', '<Leave>',
- sub {$zinc->itemconfigure('current', 0, -border => '')});
- $zinc->bind($wp.':position', '<Leave>',
- sub {$zinc->itemconfigure('current', -symbolcolor => 'green')});
- $zinc->bind($wp.':leader', '<Leave>',
- sub {$zinc->itemconfigure('current', -leadercolor => 'black')});
- $zinc->bind($wp.':connection', '<Leave>',
- sub {$zinc->itemconfigure('current', -connectioncolor => 'green')});
- $zinc->itemconfigure($wp, 0,
- -text => "$i",
- -filled => 1,
- -backcolor => 'gray55');
- $zinc->bind($wp.':position', '<1>', [\&del_way_point]);
- $x += (2.0 + rand(8.0)) * $track->{'vx'};
- $y += (2.0 + rand(8.0)) * $track->{'vy'};
- $connected = $wp;
- }
- $track->{'route'} = $wp;
- }
- else {
- $wp = $track->{'route'};
- while ($wp != $track->{'item'}) {
- $track->{'route'} = $zinc->itemcget($wp, -connecteditem);
- $zinc->bind($wp.':position', '<1>', '');
- $zinc->bind($wp.':position', '<Enter>', '');
- $zinc->bind($wp.':position', '<Leave>', '');
- $zinc->bind($wp.':leader', '<Enter>', '');
- $zinc->bind($wp.':leader', '<Leave>', '');
- $zinc->bind($wp.':connection', '<Enter>', '');
- $zinc->bind($wp.':connection', '<Leave>', '');
- $zinc->bind($wp.':0', '<Enter>', '');
- $zinc->bind($wp.':0', '<Leave>', '');
- $zinc->remove($wp);
- $wp = $track->{'route'};
- }
- $track->{'route'} = 0;
- }
-}
-
-###################################################
-# suppression waypoint intermediaire
-###################################################
-sub find_track {
- my ($zinc, $wp) = @_;
- my $connected = $wp;
-
- while ($zinc->type($connected) ne 'track') {
- $connected = $zinc->itemcget($connected, -connecteditem);
- }
- return $connected;
-}
-
-sub del_way_point {
- my ($zinc) = @_;
- my $wp = $zinc->find('withtag', 'current');
- my $track = $tracks{find_track($zinc, $wp)};
- my $next = $zinc->itemcget($wp, -connecteditem);
- my $prev;
- my $prevnext;
-
- $prev = $track->{'route'};
- if ($prev != $wp) {
- $prevnext = $zinc->itemcget($prev, -connecteditem);
- while ($prevnext != $wp) {
- $prev = $prevnext;
- $prevnext = $zinc->itemcget($prev, -connecteditem);
- }
- }
- $zinc->itemconfigure($prev, -connecteditem => $next);
- $zinc->bind($wp.':position', '<1>', '');
- $zinc->remove($wp);
- if ($wp == $track->{'route'}) {
- if ($next == $track->{'item'}) {
- $track->{'route'} = 0;
- }
- else {
- $track->{'route'} = $next;
- }
- }
-}
-
-
-###################################################
-# creation macro
-###################################################
-my $macro = $zinc->add("tabular", $radar, 10,
- -labelformat => "x73x20+0+0 x20x20+0+0 x53x20+20+0"
- );
-$zinc->itemconfigure($macro, 0, -backcolor => "tan1", -filled => 1,
- -fillpattern => "AlphaStipple7",
- -bordercolor => "red3");
-$zinc->itemconfigure($macro, 1 , -text => "a");
-$zinc->itemconfigure($macro, 2, -text => "macro");
-
-$zinc->itemconfigure($macro, -connecteditem => $one_of_track_item);
-foreach my $part (0..2) {
- $zinc->bind("$macro:$part", "<Enter>", [ \&borders, "on"]);
- $zinc->bind("$macro:$part", "<Leave>", [ \&borders, "off"]);
-}
-###################################################
-# creation ministrip
-###################################################
-my $ministrip = $zinc->add("tabular", 1, 10,
- -labelformat => "x153x80^0^0 x93x20^0^0 x63a0^0>1 a0a0>2>1 x33a0>3>1 a0a0^0>2",
- -position => [100, 10]);
-$zinc->itemconfigure($ministrip, 0 ,
- -filled => 1,
- -backcolor => "grey70",
- -border => "contour",
- -bordercolor => "green",
- );
-$zinc->itemconfigure($ministrip, 1 ,
- -text => 'ministrip', -color => "darkgreen",
- -backcolor => "grey40",
- );
-$zinc->itemconfigure($ministrip, 2 ,
- -text => 'field1', -color => "darkgreen",
- -backcolor => "grey40",
- );
-$zinc->itemconfigure($ministrip, 3 ,
- -text => 'field2', -color => "darkgreen",
- -backcolor => "grey40",
- );
-$zinc->itemconfigure($ministrip, 4 ,
- -text => 'f3', -color => "darkgreen",
- -backcolor => "grey40",
- );
-$zinc->itemconfigure($ministrip, 5 ,
- -text => 'field4', -color => "darkgreen",
- -backcolor => "grey40",
- );
-
-foreach my $field (1..5) {
- $zinc->bind("$ministrip:$field", '<Enter>',
- sub {
- $zinc->itemconfigure('current', $field,
- -border => 'contour',
- -filled => 1,
- -color => 'white'
- )
- });
-$zinc->bind("$ministrip:$field", '<Leave>',
- sub {$zinc->itemconfigure('current', $field,
- -border => '',
- -filled => 0,
- -color => 'darkgreen'
- )});
-}
-
-###################################################
-# creation map
-###################################################
-$mw->videomap("load", Tk->findINC("demos/zinc_data/videomap_paris-w_90_2"), 0, "paris-w");
-$mw->videomap("load", Tk->findINC("demos/zinc_data/videomap_orly"), 17, "orly");
-$mw->videomap("load", Tk->findINC("demos/zinc_data/hegias_parouest_TE.vid"), 0, "paris-ouest");
-
-my $map = $zinc->add("map", $radar,
- -color => 'gray80');
-$zinc->itemconfigure($map,
- -mapinfo => 'orly');
-
-my $map2 = $zinc->add("map", $radar,
- -color => 'gray60',
- -filled => 1,
- -priority => 0,
- -fillpattern => "AlphaStipple6");
-$zinc->itemconfigure($map2,
- -mapinfo => 'paris-ouest');
-
-my $map3 = $zinc->add("map", $radar,
- -color => 'gray50');
-$zinc->itemconfigure($map3,
- -mapinfo => "paris-w");
-
-
-###################################################
-# Création fonctions de contrôle à la souris
-###################################################
-new SimpleRadarControls($zinc);
-
-###################################################
-# Rafraichissement des pistes
-###################################################
-my $timer = $zinc->repeat($delay, [\&refresh, $zinc]);
-$mw->OnDestroy(\&destroyTimersub ); # this is
-
-my $timerIsDead = 0;
-sub destroyTimersub {
- $timerIsDead = 1;
- $mw->afterCancel($timer);
- # the timer is not really cancelled when using zinc-demos!
-}
-
-sub refresh {
- my ($zinc) = @_;
-
- return if $pause;
- return if $timerIsDead;
- foreach my $t (values(%tracks)) {
- $t->{'x'} += $t->{'vx'} * $rate;
- $t->{'y'} += $t->{'vy'} * $rate;
- $zinc->itemconfigure($t->{'item'},
- -position => [$t->{'x'}, $t->{'y'}]);
- }
-}
-
-sub borders {
- my($widget, $onoff) = @_;
- $onoff = "on" unless $onoff;
- my $contour = "noborder";
- $contour = "contour" if ($onoff eq 'on');
- $zinc->itemconfigure('current', 0, -border => $contour);
-}
-
-
-Tk::MainLoop();
-
-
diff --git a/Perl/demos/Tk/demos/zinc_lib/testGraphics.pl b/Perl/demos/Tk/demos/zinc_lib/testGraphics.pl
deleted file mode 100644
index 5da149b..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/testGraphics.pl
+++ /dev/null
@@ -1,1845 +0,0 @@
-#!/usr/bin/perl
-#-----------------------------------------------------------------------------------
-#
-# testGraphics.pl
-# Fichier test du module Graphics
-#
-# Authors: Jean-Luc Vinot <vinot@cena.fr>
-#
-# $Id$
-#-----------------------------------------------------------------------------------
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-use Tk::Zinc;
-use Tk::Zinc::Graphics;
-use Math::Trig;
-use Getopt::Long;
-use strict 'vars';
-
-
-my $currenttransfo;
-my $previousangle = 0;
-my $rotate_angle = .1;
-my $zoomfactor = .1;
-my $curview;
-my ($dx, $dy);
-
-my $tabanchor = 'n';
-my $tabalign = 'left';
-
-my $font_9b = '7x13bold';
-# the original font is not standard, even if it is fully free:
-# my $font_9b = '-cenapii-bleriot mini-bold-r-normal--9-90-75-75-p-75-iso8859-15';
-
-my %gradset = (# gradients zinc
- 'boitonglet' => '=axial 0|#ff7777|#ffff99',
- 'roundrect1' => '=axial 270|#a7ffa7;70 0|#ffffff;90 5|#00bd00;80 8|#b7ffb7;50 80|#ffffff;70 91|#00ac00;70 95|#006700;60 100',
- 'roundrect2' => '=axial 270|#00bd00;80 |#d7ffd7;60',
- 'roundrect3' => '=axial 270|#00bd00;100 0|#ffffff;100 14|#ffffff;100 16|#00bd00;90 25|#b7ffb7;60 100',
- 'roundrect4' => '=axial 0|#00bd00;100 0|#ffffff;100 20|#00bd00;50 30|#00bd00;90 80|#b7ffb7;60 100',
- 'roundrect4ed' => '=path 48 48|#e7ffe7;20 0 70|#007900;20',
- 'roundcurve2' => '=axial 270|#d7ffd7;60|#7777ff;80',
- 'roundcurve1' => '=axial 270|#2222ff;80 |#d7ffd7;60',
- 'roundcurve' => '=axial 270|#7777ff;80 |#d7ffd7;60',
- 'roundpolyg' => '=radial -15 -20|#ffb7b7;50|#bd6622;90',
- 'rpolyline' => '=axial 90|#ffff77;80 |#ff7700;60',
- 'pushbtn1' => '=axial 0|#cccccc;100 0|#ffffff;100 10|#5a5a6a;100 80|#aaaadd;100 100',
- 'pushbtn2' => '=axial 270|#ccccff;100 0|#ffffff;100 10|#5a5a7a;100 80|#bbbbee;100 100',
- 'pushbtn3' => '=radial -15 -15|#ffffff;100 0|#333344;100 100',
- 'pushbtn4' => '=axial 270|#ccccff;100 0|#ffffff;100 10|#7a7a9a;100 80|#bbbbee;100 100',
- 'conical_edge' => '=conical 0 0 -45|#ffffff;100 0|#888899;100 30|#555566;100 50|#888899;100 70|#ffffff;100 100',
- 'conical_ext' => '=conical 0 0 135|#ffffff;100 0|#777788;100 30|#444455;100 50|#777788;100 70|#ffffff;100 100',
- 'pushbtn_edge' => '=axial 140|#ffffff;100 0|#555566;100 100',
- 'pushbtn_edge2' => '=axial 92|#ffffff;100 0|#555566;100 100',
- 'logoshape2' => '=axial 270|#ffffff|#7192aa',
- 'logopoint2' => '=radial -20 -20|#ffffff 0|#f70000 48|#900000 80|#ab0000 100',
- 'logoptshad2' => '=path 0 0|#770000;64 0|#770000;70 78|#770000;0 100',
- );
-
-
-# contenu des pages exemples
-my %pagesconf = ('Rectangle' => {'consigne' => {-itemtype => 'text',
- -coords => [-285, 155],
- -params => {-font => $font_9b,
- -text => "Mouse button 1 drag objects,\nEscape key reset transfos.",
- -color => '#2222cc',
- },
- },
- # roudedrectangle simple + radius 20
- 'rr1' => {-itemtype => 'roundedrectangle',
- -coords => [[-200, 30], [50, 130]],
- -radius => 20,
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'roundrect2',
- -linewidth => 2,
- -linecolor => '#000000',
- -priority => 20,
- -tags => ['move'],
- },
- },
-
- # roudedrectangle 'carré' (radius automatique)
- 'rr2' => {-itemtype => 'roundedrectangle',
- -coords => [[-250, -100], [-90, 60]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'roundrect1',
- -linewidth => 3,
- -linecolor => '#000000',
- -priority => 30,
- -tags => ['move'],
- },
- },
- # cas particulier -> hippodrome (radius = h/2)
- 'rr3' => {-itemtype => 'roundedrectangle',
- -coords => [[-30, 80], [130, 160]],
- -radius => 40,
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'roundrect3',
- -linewidth => 4,
- -linecolor => '#000000',
- -priority => 30,
- -tags => ['move'],
- },
- },
-
- # utilisation de l'option -corners (pétales de fleur)
- 'rr4a' => {-itemtype => 'roundedrectangle',
- -coords => [[-30, -60], [110, 10]],
- -radius => 40,
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'roundrect3',
- -linewidth => 3,
- -linecolor => '#000000',
- -priority => 30,
- -tags => ['move'],
- },
- -corners => [1, 0, 1, 0],
- },
- 'rr4b' => {-itemtype => 'roundedrectangle',
- -coords => [[118, -68], [220, -132]],
- -radius => 40,
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'roundrect3',
- -linewidth => 3,
- -linecolor => '#000000',
- -priority => 30,
- -tags => ['move'],
- },
- -corners => [1, 0, 1, 0],
- },
- 'rr4c' => {-itemtype => 'roundedrectangle',
- -coords => [[118, -60], [190, 30]],
- -radius => 40,
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'roundrect3',
- -linewidth => 3,
- -linecolor => '#000000',
- -priority => 30,
- -tags => ['move'],
- },
- -corners => [0, 1, 0, 1],
- },
- 'rr4d' => {-itemtype => 'roundedrectangle',
- -coords => [[40, -152], [110, -68]],
- -radius => 40,
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'roundrect3',
- -linewidth => 3,
- -linecolor => '#000000',
- -priority => 30,
- -tags => ['move'],
- },
- -corners => [0, 1, 0, 1],
- },
-
- # groupe de 2 boutons avec bordure externe
- 'gr8' => {-itemtype => 'group',
- -coords => [0, 0],
- -params => {-priority => 10,
- -tags => ['move'],
- -atomic => 1,
- },
- -items => {'edge' => {-itemtype => 'roundedrectangle',
- -coords => [[174, -36],[266, 146]],
- -radius => 26,
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'roundrect4ed',
- -linewidth => 1,
- -linecolor => '#ffffff',
- -priority => 20,
- },
- },
- 'top' => {-itemtype => 'roundedrectangle',
- -coords => [[180, -30], [260, 53]],
- -parentgroup => 'gr8',
- -radius => 20,
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'roundrect4',
- -linewidth => 2.5,
- -linecolor => '#000000',
- -priority => 30,
- },
- -corners => [1, 0, 0, 1],
- },
- 'topico' => {-itemtype => 'curve',
- -parentgroup => 'gr8',
- -coords => [[220, -10],[200, 30],[240, 30]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => '#ffff00;80',
- -linewidth => 1,
- -linecolor => '#007900;80',
- -priority => 50,
- },
- },
- 'bottom' => {-itemtype => 'roundedrectangle',
- -parentgroup => 'gr8',
- -coords => [[180, 57], [260, 140]],
- -radius => 20,
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'roundrect4',
- -linewidth => 2.5,
- -linecolor => '#000000',
- -priority => 30,
- },
- -corners => [0, 1, 1, 0],
- },
- 'bottomico' => {-itemtype => 'curve',
- -parentgroup => 'gr8',
- -coords => [[220, 120],[240, 80],[200, 80]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => '#ffff00;80',
- -linewidth => 1,
- -linecolor => '#007900;80',
- -priority => 50,
- },
- },
- },
- },
- },
- 'Hippodrome' => {'consigne' => {-itemtype => 'text',
- -coords => [-285, 165],
- -params => {-font => $font_9b,
- -text => "Click hippo Buttons with mouse button 1.\n",
- -color => '#2222cc',
- },
- },
- 'hp1' => {-itemtype => 'group',
- -coords => [-163, -40],
- -params => {-priority => 40,
- },
- -items => {'edge' => {-itemtype => 'hippodrome',
- -coords => [[-46, -86], [46, 86]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn_edge',
- -linewidth => 1,
- -linecolor => '#ffffff',
- -priority => 10,
- },
- },
- 'form' => {-itemtype => 'hippodrome',
- -coords => [[-40, -80], [40, 80]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn1',
- -linewidth => 3,
- -linecolor => '#000000',
- -priority => 20,
- -tags => ['b1','pushbtn'],
- },
- },
- },
- },
-
- 'hp2' => {-itemtype => 'group',
- -coords => [-40, -40],
- -params => {-priority => 40,
- },
- -items => {'edge' => {-itemtype => 'hippodrome',
- -coords => [[-46, -86], [46, 86]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn_edge',
- -linewidth => 1,
- -linecolor => '#ffffff',
- -priority => 10,
- },
- },
- 'formT' => {-itemtype => 'hippodrome',
- -coords => [[-40, -80], [40, -28]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn1',
- -linewidth => 3,
- -linecolor => '#000000',
- -priority => 20,
- -tags => ['b2t','pushbtn'],
- },
- -orientation => 'vertical',
- -trunc => 'bottom',
- },
- 'formC' => {-itemtype => 'hippodrome',
- -coords => [[-40, -26.5], [40, 26.5]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn1',
- -linewidth => 3,
- -linecolor => '#000000',
- -priority => 20,
- -tags => ['b2c','pushbtn'],
- },
- -trunc => 'both',
- },
- 'formB' => {-itemtype => 'hippodrome',
- -coords => [[-40, 28], [40, 80]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn1',
- -linewidth => 3,
- -linecolor => '#000000',
- -priority => 20,
- -tags => ['b2b','pushbtn'],
- },
- -orientation => 'vertical',
- -trunc => 'top',
- },
- },
- },
- 'hp3edge' => {-itemtype => 'hippodrome',
- -coords => [[-204, 96], [204, 144]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn_edge2',
- -linewidth => 1,
- -linecolor => '#ffffff',
- -priority => 10,
- },
- },
- 'hp3g' => {-itemtype => 'group',
- -coords => [-160, 120],
- -params => {-priority => 40,
- },
- -items => {'form' => {-itemtype => 'hippodrome',
- -coords => [[-40, -20], [40, 20]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn2',
- -linewidth => 2,
- -linecolor => '#000000',
- -priority => 20,
- -tags => ['b3g','pushbtn'],
- },
- -trunc => 'right',
- },
- 'ico' => {-itemtype => 'curve',
- -coords => [[-20, 0],[-4, 8],[-4, -8]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => '#000000',
- -linewidth => 1,
- -linecolor => '#aaaaaa',
- -relief => 'raised',
- -priority => 30,
- -tags => ['b3g','pushbtn','ico'],
- },
- -contours => [['add',-1,[[0, 0],[16, 8],[16, -8]]]],
- },
- },
- },
- 'hp3c1' => {-itemtype => 'group',
- -coords => [-80, 120],
- -params => {-priority => 40,
- },
- -items => {'form' => {-itemtype => 'hippodrome',
- -coords => [[-38, -20], [39, 20]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn2',
- -linewidth => 2,
- -linecolor => '#000000',
- -priority => 20,
- -tags => ['b3c1','pushbtn'],
- },
- -trunc => 'both',
- },
- 'ico' => {-itemtype => 'curve',
- -coords => [[-8, 0],[8, 8],[8, -8]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => '#000000',
- -linewidth => 1,
- -linecolor => '#aaaaaa',
- -priority => 30,
- -relief => 'raised',
- -tags => ['b3c1','pushbtn','ico'],
- },
- },
- },
- },
- 'hp3c2' => {-itemtype => 'group',
- -coords => [0, 120],
- -params => {-priority => 40,
- },
- -items => {'form' => {-itemtype => 'hippodrome',
- -coords => [[-39, -20], [39, 20]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn2',
- -linewidth => 2,
- -linecolor => '#000000',
- -priority => 20,
- -tags => ['b3c2','pushbtn'],
- },
- -trunc => 'both',
- },
- 'ico' => {-itemtype => 'rectangle',
- -coords => [[-6, -6],[6, 6]],
- -params => {-filled => 1,
- -fillcolor => '#000000',
- -linewidth => 1,
- -linecolor => '#aaaaaa',
- -priority => 30,
- -tags => ['b3c2','pushbtn','ico'],
- },
- },
- },
- },
- 'hp3C3' => {-itemtype => 'group',
- -coords => [80, 120],
- -params => {-priority => 40,
- },
- -items => {'form' => {-itemtype => 'hippodrome',
- -coords => [[-39, -20], [39, 20]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn2',
- -linewidth => 2,
- -linecolor => '#000000',
- -priority => 20,
- -tags => ['b3c3','pushbtn'],
- },
- -trunc => 'both',
- },
- 'ico' => {-itemtype => 'curve',
- -coords => [[8, 0],[-8, -8],[-8, 8]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => '#000000',
- -linewidth => 1,
- -linecolor => '#aaaaaa',
- -priority => 30,
- -relief => 'raised',
- -tags => ['b3c3','pushbtn','ico'],
- },
- },
- },
- },
-
- 'hp3D' => {-itemtype => 'group',
- -coords => [160, 120],
- -params => {-priority => 40,
- },
- -items => {'form' => {-itemtype => 'hippodrome',
- -coords => [[-40, -20], [40, 20]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn2',
- -linewidth => 2,
- -linecolor => '#000000',
- -priority => 20,
- -tags => ['b3d','pushbtn'],
- },
- -trunc => 'left',
- },
- 'ico' => {-itemtype => 'curve',
- -coords => [[20, 0],[4, -8],[4, 8]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => '#000000',
- -linewidth => 1,
- -linecolor => '#aaaaaa',
- -priority => 30,
- -relief => 'raised',
- -tags => ['b3d','pushbtn','ico'],
- },
- -contours => [['add',-1,[[0,0],[-16, -8],[-16, 8]]]],
- },
- },
- },
-
- 'hp4a' => {-itemtype => 'group',
- -coords => [48, -97],
- -params => {-priority => 40,
- },
- -repeat => {-num => 2,
- -dxy => [0, 64],
- },
- -items => {'edge' => {-itemtype => 'hippodrome',
- -coords => [[-29, -29], [29, 29]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn_edge',
- -linewidth => 1,
- -linecolor => '#ffffff',
- -priority => 0,
- },
- },
- 'form' => {-itemtype => 'hippodrome',
- -coords => [[-24, -24], [24, 24]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn3',
- -linewidth => 3,
- -linecolor => '#000000',
- -priority => 30,
- -tags => ['b4a','pushbtn'],
- },
- },
- },
- },
-
- 'hp4b' => {-itemtype => 'group',
- -coords => [145, -65],
- -params => {-priority => 40,
- },
- -items => {'edge' => {-itemtype => 'hippodrome',
- -coords => [[-60, -60], [60, 60]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'conical_edge',
- -linewidth => 1,
- -linecolor => '#ffffff',
- -priority => 0,
- },
- },
- 'ext' => {-itemtype => 'hippodrome',
- -coords => [[-53, -53], [53, 53]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'conical_ext',
- -linewidth => 3,
- -linecolor => '#000000',
- -priority => 10,
- -tags => ['b4b','pushbtn'],
- },
- },
- 'int' => {-itemtype => 'hippodrome',
- -coords => [[-41, -41], [40, 40]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => '=path 10 10|#ffffff 0|#ccccd0 50|#99999f 80|#99999f;0 100',
- -linewidth => 0,
- -linecolor => '#cccccc;80',
- -priority => 30,
- -tags => ['b4b','pushbtn'],
- },
- },
- },
- },
-
- 'hp5' => {-itemtype => 'group',
- -coords => [60, 25],
- -params => {-priority => 40,
- },
- -rotate => 30,
- -repeat => {-num => 4,
- -dxy => [45, 0],
- },
- -items => {'edge' => {-itemtype => 'hippodrome',
- -coords => [[-19, -34], [19, 34]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn_edge',
- -linewidth => 1,
- -linecolor => '#ffffff',
- -priority => 10,
- },
- },
- 'form' => {-itemtype => 'hippodrome',
- -coords => [[-15, -30], [15, 30]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn1',
- -linewidth => 2,
- -linecolor => '#000000',
- -priority => 20,
- -tags => ['b5','pushbtn'],
- },
- },
- },
- },
- },
-
- 'Polygone' => {'consigne' => {-itemtype => 'text',
- -coords => [-285, 160],
- -params => {-font => $font_9b,
- -text => "Click and Drag inside Polygons for rotate them\nEscape key reset transfos.",
- -color => '#2222cc',
- },
- },
- 'triangle' => {-itemtype => 'group',
- -coords => [-215, -95],
- -items => {'form' => {-itemtype => 'polygone',
- -coords => [0, 0],
- -numsides => 3,
- -radius => 78,
- -corner_radius => 10,
- -startangle => 90,
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'roundpolyg',
- -linewidth => 2,
- -linecolor => '#330000',
- -priority => 20,
- -tags => ['p1', 'poly'],
- },
- },
- 'text' => {-itemtype => 'text',
- -coords => [0, -6],
- -params => {-font => $font_9b,
- -text => "Triangle",
- -anchor => 'n',
- -alignment => 'center',
- -color => '#660000',
- -priority => 50,
- },
- },
- },
- },
-
- 'carre' => {-itemtype => 'group',
- -coords => [-80, -75],
- -items => {'form' => {-itemtype => 'polygone',
- -coords => [0, 0],
- -numsides => 4,
- -radius => 70,
- -corner_radius => 10,
- -startangle => 90,
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'roundpolyg',
- -linewidth => 2,
- -linecolor => '#330000',
- -priority => 20,
- -tags => ['p2', 'poly'],
- },
- },
- 'text' => {-itemtype => 'text',
- -coords => [0, -6],
- -params => {-font => $font_9b,
- -text => "Carré",
- -anchor => 'n',
- -alignment => 'center',
- -color => '#660000',
- -priority => 50,
- },
- },
- },
- },
-
- 'pentagone' => {-itemtype => 'group',
- -coords => [65, -75],
- -items => {'form' => {-itemtype => 'polygone',
- -coords => [0, 0],
- -numsides => 5,
- -radius => 70,
- -corner_radius => 10,
- -startangle => 270,
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'roundpolyg',
- -linewidth => 2,
- -linecolor => '#330000',
- -priority => 20,
- -tags => ['p3', 'poly'],
- },
- },
- 'text' => {-itemtype => 'text',
- -coords => [0, -6],
- -params => {-font => $font_9b,
- -text => "Pentagone",
- -anchor => 'n',
- -alignment => 'center',
- -color => '#660000',
- -priority => 50,
- },
- },
- },
- },
-
- 'hexagone' => {-itemtype => 'group',
- -coords => [210, -75],
- -items => {'form' => {-itemtype => 'polygone',
- -coords => [0, 0],
- -numsides => 6,
- -radius => 68,
- -corner_radius => 10,
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'roundpolyg',
- -linewidth => 2,
- -linecolor => '#330000',
- -priority => 20,
- -tags => ['p4', 'poly'],
- },
- },
- 'text' => {-itemtype => 'text',
- -coords => [0, -6],
- -params => {-font => $font_9b,
- -text => "Hexagone",
- -anchor => 'n',
- -alignment => 'center',
- -color => '#660000',
- -priority => 50,
- },
- },
- },
- },
-
- 'heptagone' => {-itemtype => 'group',
- -coords => [-215, 85],
- -items => {'form' => {-itemtype => 'polygone',
- -coords => [0, 0],
- -numsides => 7,
- -radius => 64,
- -corner_radius => 10,
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'roundpolyg',
- -linewidth => 2,
- -linecolor => '#330000',
- -priority => 20,
- -tags => ['p5', 'poly'],
- },
- },
- 'text' => {-itemtype => 'text',
- -coords => [0, -6],
- -params => {-font => $font_9b,
- -text => "Heptagone",
- -anchor => 'n',
- -alignment => 'center',
- -color => '#660000',
- -priority => 50,
- },
- },
- },
- },
-
-
- 'octogone' => {-itemtype => 'group',
- -coords => [-76, 85],
- -items => {'form' => {-itemtype => 'polygone',
- -coords => [0, 0],
- -numsides => 8,
- -radius => 64,
- -corner_radius => 10,
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'roundpolyg',
- -linewidth => 2,
- -linecolor => '#330000',
- -priority => 20,
- -tags => ['p6', 'poly'],
- },
- },
- 'text' => {-itemtype => 'text',
- -coords => [0, -6],
- -params => {-font => $font_9b,
- -text => "Octogone",
- -anchor => 'n',
- -alignment => 'center',
- -color => '#660000',
- -priority => 50,
- },
- },
- },
- },
-
- 'petagone' => {-itemtype => 'group',
- -coords => [66, 85],
- -items => {'form' => {-itemtype => 'polygone',
- -coords => [0, 0],
- -numsides => 32,
- -radius => 64,
- -corner_radius => 10,
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'roundpolyg',
- -linewidth => 2,
- -linecolor => '#330000',
- -priority => 20,
- -tags => ['p7', 'poly'],
- },
- },
- 'text' => {-itemtype => 'text',
- -coords => [0, -6],
- -params => {-font => $font_9b,
- -text => "32 cotés...",
- -anchor => 'n',
- -alignment => 'center',
- -color => '#660000',
- -priority => 50,
- },
- },
- },
- },
-
- 'etoile' => {-itemtype => 'group',
- -coords => [210, 85],
- -items => {'form' => {-itemtype => 'polygone',
- -coords => [0, 0],
- -numsides => 5,
- -radius => 92,
- -inner_radius => 36,
- -corner_radius => 10,
- -startangle => 270,
- -corners => [0,1,0,1,0,1,0,1,0,1],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'roundpolyg',
- -linewidth => 2,
- -linecolor => '#330000',
- -priority => 20,
- -tags => ['p8', 'poly'],
- },
- },
- 'text' => {-itemtype => 'text',
- -coords => [0, -6],
- -params => {-font => $font_9b,
- -text => "Etoile",
- -anchor => 'n',
- -alignment => 'center',
- -color => '#660000',
- -priority => 50,
- },
- },
- },
- },
- },
-
- 'Polyline' => {'consigne' => {-itemtype => 'text',
- -coords => [-285, 155],
- -params => {-font => $font_9b,
- -text => "Mouse button 1 drag objects,\nEscape key reset transfos.",
- -color => '#2222cc',
- },
- },
- 'a' => {-itemtype => 'polyline',
- -coords => [[-200, -115],[-200, -100],[-218, -115],[-280, -115],[-280, -16],
- [-218, -16],[-200, -31],[-200, -17.5],[-150, -17.5],[-150,-115]],
- -corners_radius => [0, 0, 42, 47, 47, 42, 0, 0, 0, 0, 0, 0],
- -params => {-closed => 1,
- -filled => 1,
- -visible => 1,
- -fillcolor => 'rpolyline',
- -linewidth => 2,
- -linecolor => '#000000',
- -priority => 50,
- -tags => ['move'],
- },
- -contours => [['add', -1, [[-230, -80],[-230, -50],[-200, -50],[-200, -80]],15]],
- },
- 'b' => {-itemtype => 'polyline',
- -coords => [[-138, -150],[-138, -17.5],[-88, -17.5],[-88, -31],[-70, -16],
- [-8, -16],[-8, -115],[-70, -115],[-88, -100],[-88, -150]],
- -corners_radius => [0, 0, 0, 0, 42, 47, 47, 42, 0, 0, 0, 0, 0, 0],
- -params => {-closed => 1,
- -filled => 1,
- -visible => 1,
- -fillcolor => 'rpolyline',
- -linewidth => 2,
- -linecolor => '#000000',
- -priority => 50,
- -tags => ['move'],
- },
- -contours => [['add', -1, [[-88, -80],[-88, -50],[-58, -50],[-58, -80]],15]],
- },
- 'c' => {-itemtype => 'polyline',
- -coords => [[80, -76],[80, -110],[60, -115],[0, -115],[0, -16],
- [60, -16],[80, -21],[80, -57],[50, -47],[50, -86]],
- -corners_radius => [0, 0, 70, 47, 47, 70, 0, 0, 14, 14, 0, 0, 0,0 ],
- -params => {-closed => 1,
- -filled => 1,
- -visible => 1,
- -fillcolor => 'rpolyline',
- -linewidth => 2,
- -linecolor => '#000000',
- -priority => 50,
- -tags => ['move'],
- },
- },
- 'spirale' => {-itemtype => 'polyline',
- -coords => [[215, -144],[139, -144],[139, 0],[268, 0],[268, -116],
- [162.5, -116],[162.5, -21],[248, -21],[248, -96],[183, -96],
- [183, -40],[231,-40],[231, -80],[199, -80],[199, -55],[215, -55]],
- -corners_radius => [0, 76, 68, 61, 55, 50, 45, 40, 35, 30, 26, 22, 18, 14, 11],
- -params => {-closed => 1,
- -filled => 1,
- -visible => 1,
- -fillcolor => 'rpolyline',
- -linewidth => 2,
- -linecolor => '#000000',
- -priority => 50,
- -tags => ['move'],
- },
- },
- 'logo' => {-itemtype => 'group',
- -coords => [0, 0],
- -params => {-priority => 30,
- -atomic => 1,
- -tags => ['move'],
- },
- -items => {'tkzinc' => {-itemtype => 'polyline',
- -coords => [[-150,10],[-44,10],[-44,68],[-28,51],[6,51],
- [-19,79],[3,109],[53,51],[5,51],[5,10],[140,10],
- [52,115],[96,115],[96,47],[196,47],[196,158],
- [155,158],[155,89],[139,89],[139,160],[101, 160],
- [101,132],[85,132],[85,160],[-42,160],[-2,115],
- [-30,115],[-46,91],[-46,115],[-76,115],[-76,51],
- [-98,51],[-98,115],[-130,115],[-130,51],[-150, 51]],
- -corners_radius => [0,0,0,0,0,0,0,0,0,0,30,0,0,50,50,
- 0,0,8,8,0,0,8,8,0,27],
- -params => {-closed => 1,
- -filled => 1,
- -visible => 1,
- -fillcolor => 'logoshape2',
- -linewidth => 2.5,
- -linecolor => '#000000',
- -priority => 10,
- -fillrule => 'nonzero',
- },
-
- -contours => [['add', 1, [[245,88],[245,47],[190,47],[190,158],
- [259,158],[259,117],[230,117],[230,88]],
- 5, undef, [0,0,55,55,0,0,15,15]]],
- },
- 'shad' => {-itemtype => 'arc',
- -coords => [[75, 91],[115,131]],
- -params => {-priority => 20,
- -filled => 1,
- -linewidth => 0,
- -fillcolor => 'logoptshad2',
- -closed => 1,
- },
- },
- 'point' => {-itemtype => 'arc',
- -coords => [[70, 86],[110,126]],
- -params => {-priority => 50,
- -filled => 1,
- -linewidth => 1,
- -linecolor => '#a10000',
- -fillcolor => 'logopoint2',
- -closed => 1,
- },
- },
- },
- },
- },
-
- 'MultiContours' => {'consigne' => {-itemtype => 'text',
- -coords => [-285, 155],
- -params => {-font => $font_9b,
- -text => "Mouse button 1 drag objects,\nEscape key reset transfos.",
- -color => '#2222cc',
- },
- },
- 'mc1' => {-itemtype => 'roundedcurve',
- -coords => [[-30, -170], [-130, 0],[70, 0]],
- -radius => 14,
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'roundcurve2',
- -linewidth => 1,
- -linecolor => '#000000',
- -priority => 20,
- -tags => ['move'],
- -fillrule => 'odd',
- },
- -contours => [['add',1,[[-30,-138],[-100,-18],[40,-18]],8],
- ['add',1,[[-30,-130],[ -92,-22],[32,-22]],5],
- ['add',1,[[-30,-100],[ -68,-36],[8,-36]],5],
- ['add',1,[[-30, -92],[ -60,-40],[0,-40]],3],],
- },
- 'mc2' => {-itemtype => 'polyline',
- -coords => [[-250,-80], [-240,-10],[-285,-10],[-285,80],
- [-250, 80],[-250, 40],[-170, 40],[-170,80],
- [-100,80],[-100,40],[-20,40],[-20,80],[30,80],
- [-10, 0],[-74, -10],[-110, -80]],
- -corners_radius => [24,4, 40, 20, 0, 40, 40, 0, 0, 40, 40, 0, 30, 75, 0, 104],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'roundcurve1',
- -linewidth => 2,
- -linecolor => '#000000',
- -priority => 30,
- -tags => ['move'],
- },
- -contours => [['add',-1,[[-240,-72],[-230,0],[-169,0],[-185, -72]],
- 0, undef, [16, 16, 0, 0]],
- ['add', -1, [[-175,-72],[-159,0],[-78,0],[-116, -72]],
- 0, undef, [0, 0, 8, 88]],
- ['add', 1, [[-245,45],[-245,115],[-175,115],[-175, 45]],
- 35],
- ['add', -1, [[-225,65],[-225,95],[-195,95],[-195, 65]],
- 15],
- ['add', 1, [[-95,45],[-95,115],[-25,115],[-25, 45]],
- 35],
- ['add', -1, [[-75,65],[-75,95],[-45,95],[-45, 65]],
- 15],
- ],
- },
- 'mc3' => {-itemtype => 'roundedcurve',
- -coords => [[-10, 170], [256, 170],[312, 60],[48, 60]],
- -radius => 34,
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'roundcurve2',
- -linewidth => 2.5,
- -linecolor => '#000000',
- -priority => 40,
- -tags => ['move'],
- },
- -contours => [['add', -1, [[58, 62],[12, 144],[60, 172],[104, 88]],27],
- ['add', 1, [[48, 77],[48, 119],[90, 119],[90, 77]],21],
- ['add', -1, [[244, 58],[198, 140],[246, 168],[290, 84]],27],
- ['add', 1, [[213, 110],[213, 152],[255, 152],[255, 110]],21],
- ['add', -1, [[150, 60],[150, 170],[160, 170],[160, 60]],0]],
- },
- 'mc4' => {-itemtype => 'roundedcurve',
- -coords => [[222, -150],[138, -150],[180, -50],[138, -150],
- [80, -92],[180, -50],[80, -92],[80, -8],
- [180, -50],[80, -8],[138, 50],[180, -50],
- [138, 50],[222, 50],[179.8, -50],[222, 50],
- [280, -8],[180, -50],[280, -8],[280, -92],
- [180, -50],[280, -92],[222,-150],[180,-50]],
- -radius => 28,
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'roundcurve',
- -linewidth => 2,
- -linecolor => '#000000',
- -priority => 30,
- -tags => ['move'],
- },
- -contours => [['add', -1, [[160, -70],[160, -30],[200, -30],[200, -70]],20]],
- },
- },
-
- 'TabBox' => {'consigne' => {-itemtype => 'text',
- -coords => [-285, 160],
- -params => {-font => $font_9b,
- -text => "Click on thumbnail to select page\nChange anchor or alignment tabs options with radio buttons.\n",
- -color => '#2222cc',
- },
- },
-
- 'exemple' => {-itemtype => 'text',
- -coords => [-165, -105],
- -params => {-font => $font_9b,
- -text => "",
- -alignment => 'left',
- -anchor => 'nw',
- -color => '#000000',
- -priority => 500,
- -width => 350,
- -tags => ['div2', 'fontname'],
- },
- },
-
- 'bo1' => {-itemtype => 'tabbox',
- -coords => [[-240, -160], [240, 100]],
- -radius => 8,
- -tabwidth => 72,
- -tabheight => 28,
- -numpages => 8,
- -anchor => 'n',
- -alignment => 'left',
- -overlap => 3,
- -params => {-closed => 1,
- -priority => 100,
- -filled => 1,
- -fillcolor => '#ffffff',
- -linewidth => 1.2,
- -linecolor => '#000000',
- -tags => ['div2', 'divider'],
- },
- -tabtitles => {-text => ['A', 'B', 'C', 'D', 'E', 'F','G','H'],
- -params => {-text => 'titre',
- -color => '#2222cc',
- -font => $font_9b,
- -anchor => 'center',
- -alignment => 'center',
- -priority => 400,
- -visible => 1,
- },
- },
- },
-
- 'back' => {-itemtype => 'roundedrectangle',
- -coords => [[-242, -162], [242, 102]],
- -radius => 10,
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => '#777777;80',
- -linewidth => 1,
- -linecolor => '#777777;80',
- },
- },
-
- 'anchor' => {-itemtype => 'text',
- -coords => [-120, 115],
- -params => {-text => 'tabs anchor',
- -color => '#2222cc',
- -font => $font_9b,
- -anchor => 'center',
- -alignment => 'center',
- -priority => 40,
- },
- },
-
- 'anchorN' => {-itemtype => 'hippodrome',
- -coords => [[-210, 125], [-165, 151]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn4',
- -linewidth => 1.5,
- -linecolor => '#000000',
- -priority => 20,
- -tags => ['sel1','n','btn','selector'],
- },
- -trunc => 'right',
- },
- 'txtanN' => {-itemtype => 'text',
- -coords => [-187, 138],
- -params => {-text => 'N',
- -color => '#000000',
- -font => $font_9b,
- -anchor => 'center',
- -alignment => 'center',
- -priority => 40,
- -tags => ['sel1','n','btntext','selector'],
- },
- },
-
- 'anchorE' => {-itemtype => 'hippodrome',
- -coords => [[-163, 125], [-120, 151]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn4',
- -linewidth => 1.5,
- -linecolor => '#000000',
- -priority => 20,
- -tags => ['sel1','e','btn','selector'],
- },
- -trunc => 'both',
- },
- 'txtanE' => {-itemtype => 'text',
- -coords => [-141.5, 138],
- -params => {-text => 'E',
- -color => '#000000',
- -font => $font_9b,
- -anchor => 'center',
- -alignment => 'center',
- -priority => 40,
- -tags => ['sel1','e','btntext','selector'],
- },
- },
-
- 'anchorS' => {-itemtype => 'hippodrome',
- -coords => [[-118, 125], [-75, 151]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn4',
- -linewidth => 1.5,
- -linecolor => '#000000',
- -priority => 20,
- -tags => ['sel1','s','btn','selector'],
- },
- -trunc => 'both',
- },
- 'txtanS' => {-itemtype => 'text',
- -coords => [-96.5, 138],
- -params => {-text => 'S',
- -color => '#000000',
- -font => $font_9b,
- -anchor => 'center',
- -alignment => 'center',
- -priority => 40,
- -tags => ['sel1','s','btntext','selector'],
- },
- },
- 'anchorW' => {-itemtype => 'hippodrome',
- -coords => [[-73, 125], [-28, 151]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn4',
- -linewidth => 1.5,
- -linecolor => '#000000',
- -priority => 20,
- -tags => ['sel1','w','btn','selector'],
- },
- -trunc => 'left',
- },
- 'txtanW' => {-itemtype => 'text',
- -coords => [-52, 138],
- -params => {-text => 'W',
- -color => '#000000',
- -font => $font_9b,
- -anchor => 'center',
- -alignment => 'center',
- -priority => 40,
- -tags => ['sel1','w','btntext','selector'],
- },
- },
- 'alignment' => {-itemtype => 'text',
- -coords => [120, 115],
- -params => {-text => 'tabs alignment',
- -color => '#2222cc',
- -font => $font_9b,
- -anchor => 'center',
- -alignment => 'center',
- -priority => 40,
- },
- },
- 'alignG' => {-itemtype => 'hippodrome',
- -coords => [[30, 125], [90, 151]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn4',
- -linewidth => 1.5,
- -linecolor => '#000000',
- -priority => 20,
- -tags => ['sel2','left','btn','selector'],
- },
- -trunc => 'right',
- },
- 'txtalG' => {-itemtype => 'text',
- -coords => [60, 138],
- -params => {-text => 'left',
- -color => '#000000',
- -font => $font_9b,
- -anchor => 'center',
- -alignment => 'center',
- -priority => 40,
- -tags => ['sel2','left','btntext','selector'],
- },
- },
- 'alignC' => {-itemtype => 'hippodrome',
- -coords => [[92, 125], [148, 151]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn4',
- -linewidth => 1.5,
- -linecolor => '#000000',
- -priority => 20,
- -tags => ['sel2','center','btn','selector'],
- },
- -trunc => 'both',
- },
- 'txtalC' => {-itemtype => 'text',
- -coords => [120, 138],
- -params => {-text => 'center',
- -color => '#000000',
- -font => $font_9b,
- -anchor => 'center',
- -alignment => 'center',
- -priority => 40,
- -tags => ['sel2','center','btntext','selector'],
- },
- },
- 'alignD' => {-itemtype => 'hippodrome',
- -coords => [[150, 125], [210, 151]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'pushbtn4',
- -linewidth => 1.5,
- -linecolor => '#000000',
- -priority => 20,
- -tags => ['sel2','right','btn','selector'],
- },
- -trunc => 'left',
- },
- 'txtalD' => {-itemtype => 'text',
- -coords => [180, 138],
- -params => {-text => 'right',
- -color => '#000000',
- -font => $font_9b,
- -anchor => 'center',
- -alignment => 'center',
- -priority => 40,
- -tags => ['sel2','right','btntext','selector'],
- },
- },
- },
-
- 'PathLine' => {'consigne' => {-itemtype => 'text',
- -coords => [-285, 155],
- -params => {-font => $font_9b,
- -text => "Mouse button 1 drag objects,\nEscape key reset transfos.",
- -color => '#2222cc',
- },
- },
- 'pl1' => {-itemtype => 'pathline',
- -metacoords => {-type => 'polygone',
- -coords => [0, 0],
- -numsides => 12,
- -radius => 200,
- -inner_radius => 100,
- -startangle => -8,
- },
- -linewidth => 20,
- -closed => 1,
- -graduate => {-type => 'linear',
- -colors => ['#ff0000', '#ff00ff', '#0000ff', '#00ffff',
- '#00ff00', '#ffff00', '#ff0000'],
- },
- -params => {-priority => 100,
- -tags => ['move'],
- },
- },
-
- 'pl2' => {-itemtype => 'group',
- -coords => [0, 0],
- -params => {-priority => 200,
- -atomic => 1,
- -tags => ['move'],
- },
- -items => {'in' => {-itemtype => 'pathline',
- -coords => [[30, -60],[-30, -60],[-30, -30],
- [-60, -30],[-60, 30],[-30, 30],
- [-30, 60],[30, 60],[30, 30],
- [60, 30],[60, -30],[30, -30]],
- -linewidth => 16,
- -closed => 1,
- -shifting => 'left',
- -graduate => {-type => 'transversal',
- -colors => ['#00aa77;100', '#00aa77;0'],
- },
- -params => {-priority => 10,
- },
- },
-
- 'out' => {-itemtype => 'pathline',
- -coords => [[30, -60],[-30, -60],[-30, -30],
- [-60, -30],[-60, 30],[-30, 30],
- [-30, 60],[30, 60],[30, 30],
- [60, 30],[60, -30],[30, -30]],
- -linewidth => 10,
- -closed => 1,
- -shifting => 'in',
- -graduate => {-type => 'transversal',
- -colors => ['#00aa77;100', '#00aa77;0'],
- },
- -params => {-priority => 10,
- },
- },
- },
- },
-
- 'pl3' => {-itemtype => 'group',
- -coords => [0, 0],
- -params => {-priority => 100,
- -atomic => 1,
- -tags => ['move'],
- },
- -items => {'back' => {-itemtype => 'arc',
- -coords => [[-150, -150],[150,150]],
- -params => {-priority => 10,
- -closed => 1,
- -filled => 1,
- -fillcolor => '=radial 15 15|#ffffff;40|#aaaaff;10',
- -linewidth => 0,
- },
- },
- 'light' => {-itemtype => 'pathline',
- -metacoords => {-type => 'polygone',
- -coords => [0, 0],
- -numsides => 30,
- -radius => 150,
- -startangle => 240,
- },
- -linewidth => 20,
- -shifting => 'in',
- -closed => 1,
- -graduate => {-type => 'double',
- -colors => [['#ffffff;0', '#222299;0', '#ffffff;0'],
- ['#ffffff;100', '#222299;70', '#ffffff;100']],
- },
- -params => {-priority => 50,
- },
- },
- 'bord' => {-itemtype => 'arc',
- -coords => [[-150, -150],[150,150]],
- -params => {-priority => 100,
- -closed => 1,
- -filled => 0,
- -linewidth => 2,
- -linecolor => '#000033;80'
- },
- },
-
- },
- },
- },
-
- );
-
-my %tabtable = ('n' => {-numpages => 8,
- -titles => ['A','B','C','D','E','F','G','H'],
- -names => ['ATOMIC GROUP :','BIND COMMAND :','CURVE ITEMS :','DISPLAY LIST :',
- 'EVENTS SENSITIVITY :','FIT COMMAND :','GROUP ITEMS','HASTAG COMMAND'],
- -texts => ["It may seem at first that there is a contradiction in this title, but there is not. [...] So groups have a feature, the atomic attribute, that is used to seal a group so that events cannot propagate past it downward. If an item part of an atomic group is under the pointer, TkZinc will try to trigger bindings associated with the atomic group not with the item under the pointer. This improves greatly the metaphor of an indivisible item.",
- "This widget command is similar to the Tk bind command except that it operates on TkZinc items instead of widgets. Another difference with the bind command is that only mouse and keyboard related events can be specified (such as Enter, Leave, ButtonPress, ButtonRelease, Motion, KeyPress, KeyRelease). The bind manual page is the most accurate place to look for a definition of sequence and command and for a general understanding of how the binding mecanism works.",
- "Items of type curve display pathes of line segments and/or cubic bezier connected by their end points. A cubic Bezier is defined by four points. The first and last ones are the extremities of the cubic Bezier. The second and the third ones are control point (i.e. they must have a third ``coordinate'' with the value 'c'). If both control points are identical, one may be omitted. As a consequence, it is an error to have more than two succcessive control points or to start or finish a curve with a control point.",
- "The items are arranged in a display list for each group. The display list imposes a total ordering among its items. The group display lists are connected in a tree identical to the group tree and form a hierarchical display list. The items are drawn by traversing the display list from the least visible item to the most visible one.The search to find the item that should receive an event is done in the opposite direction. In this way, items are drawn according to their relative stacking order and events are dispatched to the top-most item at a given location.",
- "An item will catch an event if all the following conditions are satisfied: * the item -sensitive must be set to true (this is the default). * the item must be under the pointer location. * the item must be on top of the display list (at the pointer location). Beware that an other item with its -visible set to false DOES catch event before any underneath items. * the item must not be clipped (at the pointer location) * the item must not belong to an atomic group, since an atomic group catchs the event instead of the item.",
- "This command fits a sequence of Bezier segments on the curve described by the vertices in coordList and returns a list of lists describing the points and control points for the generated segments. All the points on the fitted segments will be within error distance from the given curve. coordList should be either a flat list of an even number of coordinates in x, y order or a list of lists of point coordinates X, Y. The returned list can be directly used to create or change a curve item contour.",
- "Groups are very powerful items. They have no graphics of their own but are used to bundle items together so that they can be manipulated easily as a whole. Groups can modify in several way how items are displayed and how they react to events. They have many uses in TkZinc. The main usages are to bundle items, to interpose a new coordinate system in a hierarchy of items, to compose some specific attributes, to apply a clipping to their children items, to manage display",
- "This command returns a boolean telling if the item specified by tagOrId has the specified tag. If more than one item is named by tagOrId, then the topmost in display list order is used to return the result. If no items are named by tagOrId, an error is raised.",
- ],
- },
- 'e' => {-numpages => 5,
- -titles => ['I','J','K','L','M'],
- -names => ['ITEM IDS','JOINSTYLE ATTRIBUTE','K :','LOWER COMMAND','MAP ITEM :'],
- -texts => ["Each item is associated with a unique numerical id which is returned by the add or clone commands. All commands on items accept those ids as (often first) parameter in order to uniquely identify on which item they should operate. When an id has been allocated to an item, it is never collected even after the item has been destroyed, in a TkZinc session two items cannot have the same id. This property can be quite useful when used in conjonction with tags, which are described below.",
- "Specifies the form of the joint between the curve segments. This attribute is only applicable if the curve outline relief is flat. The default value is round.",
- "No TkZinc KeyWord with K initial letter...",
- "Reorder all the items given by tagOrId so that they will be under the item given by belowThis. If tagOrId name more than one item, their relative order will be preserved. If tagOrId doesn't name an item, an error is raised. If belowThis name more than one item, the bottom most them is used. If belowThis doesn't name an item, an error is raised. If belowThis is omitted the items are put at the bottom most position of their respective groups.",
- "Map items are typically used for displaying maps on a radar display view. Maps are not be sensitive to mouse or keyboard events, but have been designed to efficiently display large set of points, segments, arcs, and simple texts. A map item is associated to a mapinfo. This mapinfo entity can be either initialized with the videomap command or more generally created and edited with a set of commands described in the The mapinfo related commands section.",
- ],
- },
- 's' => {-numpages => 8,
- -titles => ['N','O','P','Q','R','S','T','U'],
- -names => ['NUMPARTS COMMAND :','OVERLAP MANAGER :','PICKAPERTURE WIDGET OPTION :','Q :',
- 'RENDER WIDGET OPTION :','SMOOTH COMMAND','TAGS :', 'UNDERLINED ATTRIBUTE :'],
- -texts => ["This command tells how many fieldId are available for event bindings or for field configuration commands in the item specified by tagOrId. If more than one item is named by tagOrId, the topmost in display list order is used to return the result. If no items are named by tagOrId, an error is raised. This command returns always 0 for items which do not support fields. The command hasfields may be used to decide whether an item has fields.",
- "his option accepts an item id. It specifies if the label overlapping avoidance algorithm should be allowed to do its work on the track labels and which group should be considered to look for tracks. The default is to enable the avoidance algorithm in the root group (id 1). To disable the algorithm this option should be set to 0.",
- "Specifies the size of an area around the pointer that is used to tell if the pointer is inside an item. This is useful to lessen the precision required when picking graphical elements. This value must be a positive integer. It defaults to 1.",
- "No TkZinc KeyWord with Q initial letter...",
- "Specifies whether to use or not the openGL rendering. When True, requires the GLX extension to the X server. Must be defined at widget creation time. This option is readonly and can be used to ask if the widget is drawing with the GLX extension or in plain X (to adapt the application code for example). The default value is false.",
- "This command computes a sequence of Bezier segments that will smooth the polygon described by the vertices in coordList and returns a list of lists describing thr points and control points for the generated segments. coordList should be either a flat list of an even number of coordinates in x, y order, or a list of lists of point coordinates X, Y. The returned list can be used to create or change the contour of a curve item.",
- "Apart from an id, an item can be associated with as many symbolic names as it may be needed by an application. Those names are called tags and can be any string which does not form a valid id (an integer). However the following characters may not be used to form a tag: . * ! ( ) & | :. Tags exists, and may be used in commands, even if no item are associated with them. In contrast an item id doesn't exist if its item is no longer around and thus it is illegal to use it.",
- "Item Text attribute. If true, a thin line will be drawn under the text characters. The default value is false.",
- ],
- },
- 'w' => {-numpages => 5,
- -titles => ['V','W','X','Y','Z'],
- -names => ['VERTEXAT COMMAND :','WAYPOINT ITEM :','X11, OpenGL and Windows :','Y...','ZINC an advanced scriptable Canvas :'],
- -texts => ["Return a list of values describing the vertex and edge closest to the window coordinates x and y in the item described by tagOrId. If tagOrId describes more than one item, the first item in display list order that supports vertex picking is used. The list consists of the index of the contour containing the returned vertices, the index of the closest vertex and the index of a vertex next to the closest vertex that identify the closest edge (located between the two returned vertices).",
- "Waypoints items have been initially designed for figuring out typical fixed position objects (i.e. beacons or fixes in the ATC vocabulary) with associated block of texts on a radar display for Air Traffic Control. They supports mouse event handling and interactions. However they may certainly be used by other kinds of radar view or even by other kind of plan view with many geographical objects and associated textual information.",
- "TkZinc was firstly designed for X11 server. Since the 3.2.2 version, TkZinc also offers as a runtime option, the support for openGL rendering, giving access to features such as antialiasing, transparency, color gradients and even a new, openGL oriented, item type : triangles . In order to use the openGL features, you need the support of the GLX extension on your X11 server. We also succeeded in using TkZinc with openGL on the Exceed X11 server (running on windows and developped by Hummingbird) with the 3D extension. ",
- "No TkZinc KeyWord with Y initial letter...",
- "TkZinc widgets are very similar to Tk Canvases in that they support structured graphics. But unlike the Canvas, TkZinc can structure the items in a hierarchy, has support for affine 2D transforms, clipping can be set for sub-trees of the item hierarchy, the item set is quite more powerful including field specific items for Air Traffic systems and new rendering techniques such as transparency and gradients. If needed, it is also possible to extend the item set in an additionnal dynamic library through the use of a C api.",
- ],
- },
- );
-
-
-# creation de la fenetre principale
-my $mw = MainWindow->new();
-$mw->geometry("700x560+0+0");
-$mw->title('Test Graphics Module');
-
-
-# creation du widget Zinc
-my $zinc = $mw->Zinc(-render => 1,
- -width => 700,
- -height => 560,
- -borderwidth => 0,
- -lightangle => 140,
- -borderwidth => 0,
- -backcolor => '#cccccc',);
-$zinc->pack(-fill => 'both', -expand => 1);
-
-
-# initialise les gradients nommés
-&setGradients($zinc, \%gradset);
-
-# création de la vue principale
-my $tgroup = $zinc->add('group', 1);
-$zinc->coords($tgroup, [350, 240]);
-
-# consigne globale
-$zinc->add('text', 1,
- -position => [50, 470],
- -text => "Global interations :\n<Up>, <Down>, <Left> and <Right> keys move content of TabBox pages\n<Plus> and <Minus> keys zoom out and zoom in this page\n<Greater> and <Less> keys rotate this page\n<Escape> key reset transfos",
- -font => $font_9b,
- -color => '#555555',
- -spacing => 2,
- );
-
-# Création des pages d'exemples
-my ($shapes, $tcoords) = &tabBoxCoords([[-315, -210],[315, 210]],
- -numpages => 7,
- -overlap => 2,
- -radius => 8,
- -tabheight => 26,
- -tabwidth => [92,100,82,82,82,120,80],
- );
-
-# to find some images (used as textures) needed by this demo
-my $texture = $zinc->Photo('paper.gif', -file => Tk->findINC('demos/zinc_data/paper.gif'));
-
-# création des items zinc correspondants
-my $i = scalar(@{$shapes}) - 1;
-my @pagenames = ('Rectangle', 'Hippodrome', 'Polygone', 'Polyline', 'PathLine', 'MultiContours', 'TabBox');
-my @pagegroups;
-foreach my $shape (reverse @{$shapes}) {
- my $divgroup = $zinc->add('group', $tgroup);
-
- # création de l'intercalaire
- my $divider = $zinc->add('curve', $divgroup,
- $shape,
- -closed => 1,
- -priority => 10,
- -linewidth => 1,
- -linecolor => '#000000',
- -filled => 1,
- -tile => $texture,
- -tags => ['div1', 'divider', $i, 'intercalaire'],
- );
-
- # groupe page clippé
- my $page = $zinc->add('group', $divgroup,
- -priority => 100,
- -tags => ['div1', $i, 'page'],
- );
- my $clip = $zinc->add('rectangle', $page,
- [[-300, -170],[300, 195]],
- -linewidth => 1,
- -linecolor => '#000099',
- -filled => 1,
- -fillcolor => '#000000;4',
- );
- $zinc->itemconfigure($page, -clip => $clip);
-
- my $pgroup = $zinc->add('group', $page,
- -tags => ['div1', $i, 'content'],
- );
-
- push(@pagegroups, $pgroup);
-
- $tcoords->[$i]->[1] -= 6;
-
- # titre de l'intercalaire
- $zinc->add('text', $divgroup,
- -position => $tcoords->[$i],
- -text => $pagenames[$i],
- -font => $font_9b,
- -alignment => 'center',
- -anchor => 'n',
- -color => '#000099',
- -priority => 200,
- -tags => ['div1', 'divider', $i, 'titre'],
- );
- $i--;
-}
-
-# création du contenu des pages
-$i = 0;
-foreach my $pagename (reverse @pagenames) {
- my $pagestyle = $pagesconf{$pagename};
- if ($pagestyle) {
-
- my $pgroup = $pagegroups[$i];
- while (my ($itemname, $itemstyle) = each(%{$pagestyle})) {
- my $group = ($itemname eq 'consigne') ? $zinc->group($pgroup) : $pgroup;
- $itemstyle->{'-name'} = $itemname;
- &buildZincItem($zinc, $group, %{$itemstyle});
- }
- }
-
- $i++;
-}
-
-
-# initialisation de la TabBox
-&clickSelector('sel1','n');
-&clickSelector('sel2','left');
-&selectDivider('div1', 0);
-
-# initialisation des bindings
-&setBindings;
-
-
-MainLoop;
-#----------------------------------------------------------------------- fin de MAIN
-
-
-sub setBindings {
- # grab keyboard
- $mw->Tk::focus();
-
- # plus,moins : Zoom++, Zoom--
- $mw->Tk::bind('<plus>', sub {viewZoom('up');});
- $mw->Tk::bind('<minus>', sub {viewZoom('down');});
-
- # Up, Down, Right, Left : Translate
- $mw->Tk::bind('<KeyPress-Up>', sub {viewTranslate('up');});
- $mw->Tk::bind('<KeyPress-Down>', sub {viewTranslate('down');});
- $mw->Tk::bind('<KeyPress-Left>', sub {viewTranslate('left');});
- $mw->Tk::bind('<KeyPress-Right>', sub {viewTranslate('right');});
-
-
- # >, < : Rotate counterclockwise et clockwise
- $mw->Tk::bind('<greater>', sub {viewRotate('cw');});
- $mw->Tk::bind('<less>', sub {viewRotate('ccw');});
-
- # Escape : reset transfos
- $mw->Tk::bind('<Escape>', sub {$zinc->treset('move');
- $zinc->raise('move');
- $zinc->treset($curview);});
-
- $zinc->bind('divider', '<1>', sub {&selectDivider();});
-
- $zinc->bind('selector', '<1>', sub {&clickSelector();});
-
- $zinc->bind('move', '<1>', sub {&mobileStart();});
- $zinc->bind('move', '<B1-Motion>', sub {&mobileMove();});
- $zinc->bind('move', '<ButtonRelease>', sub {&mobileStop();});
-
- $zinc->bind('pushbtn', '<1>', sub {&pushButton();});
- $zinc->bind('pushbtn', '<ButtonRelease>', sub {&pullButton();});
-
- $zinc->bind('poly', '<1>', sub {&startRotatePolygone();});
- $zinc->bind('poly', '<B1-Motion>', sub {&rotatePolygone();});
-}
-
-
-#-----------------------------------------------------------------------------------
-# Callback sur evt CLICK des items tagés 'divider'
-#-----------------------------------------------------------------------------------
-sub selectDivider {
- my ($divname, $numpage) = @_;
- if (!defined $divname) {
- my @tags = $zinc->itemcget('current', -tags);
- $divname = $tags[0];
- $numpage = $tags[2];
- }
-
- $zinc->itemconfigure("($divname && titre)", -color => '#000099');
- $zinc->itemconfigure("($divname && intercalaire)", -linewidth => 1.4);
- $zinc->itemconfigure("($divname && page)", -visible => 0);
-
- my $divgroup = $zinc->group("($divname && $numpage)");
- $zinc->raise($divgroup);
- $curview = "($divname && $numpage && content)";
- $zinc->itemconfigure("($divname && $numpage && titre)", -color => '#000000');
- $zinc->itemconfigure("($divname && $numpage && intercalaire)", -linewidth => 2);
- $zinc->itemconfigure("($divname && $numpage && page)", -visible => 1);
-
- if ($divname eq 'div2') {
- my $fontname = $tabtable{$tabanchor}->{'-names'}->[$numpage];
- my $explain = $tabtable{$tabanchor}->{'-texts'}->[$numpage];
- my $text = $fontname."\n\n".$explain;
- $zinc->itemconfigure("($divname && fontname)",
- -text => $text);
- $zinc->raise("($divname && fontname)");
- }
-}
-
-
-#-----------------------------------------------------------------------------------
-# Callback sur evt CLICK des items tagés 'selector'
-#-----------------------------------------------------------------------------------
-sub clickSelector {
- my ($btngroup, $value) = @_;
-
- if (!defined $btngroup and !defined $value) {
- my @tags = $zinc->itemcget('current', -tags);
- $btngroup = $tags[0];
- $value = $tags[1];
- }
-
- $zinc->treset($btngroup);
- $zinc->itemconfigure("($btngroup && btntext)", -color => '#444444');
- $zinc->itemconfigure("($btngroup && $value && btntext)", -color => '#2222bb');
- $zinc->translate("($btngroup && $value)", 0, 1);
-
- if ($value eq 'n' or $value eq 'e' or $value eq 's' or $value eq 'w') {
- $tabanchor = $value;
-
- } elsif ($value eq 'left' or $value eq 'center' or $value eq 'right') {
- $tabalign = $value;
- }
-
- my $tabtable = $tabtable{$tabanchor};
- my $numpages = $tabtable->{'-numpages'};
- my %tabparams = (-radius => 8,
- -tabwidth => 72,
- -tabheight => 28,
- -numpages => $numpages,
- -anchor => $tabanchor,
- -alignment => $tabalign,
- -overlap => 3,
- );
-
- my ($shapes, $tcoords) = &tabBoxCoords([[-240, -160], [240, 100]], %tabparams);
-
- for (my $index = 7; $index >= 0; $index--) {
- my $divgroup = $zinc->group("(div2 && $index && intercalaire)");
- $zinc->itemconfigure($divgroup, -visible => ($index < $numpages));
-
- if ($index >= $numpages) {
- $zinc->lower($divgroup);
-
- } else {
- $zinc->raise($divgroup);
- $zinc->itemconfigure("(div2 && $index)", -visible => 1);
- $zinc->coords("(div2 && $index && intercalaire)", $shapes->[$index]);
- if ($zinc->type("(div2 && $index && titre)")) {
- $zinc->coords("(div2 && $index && titre)", $tcoords->[$index]);
- $zinc->itemconfigure("(div2 && $index && titre)", -text => $tabtable->{'-titles'}->[$index]);
- }
- }
-
- }
-
- &selectDivider('div2', 0);
-}
-
-
-#-----------------------------------------------------------------------------------
-# Callback sur evt CLICK des items tagés 'pushbtn'
-#-----------------------------------------------------------------------------------
-sub pushButton {
- my $tag = ($zinc->itemcget('current', -tags))[0];
- if (scalar $zinc->find('withtag', $tag) > 1 and
- !$zinc->find('withtag', "($tag && ico)")) {
- $tag = 'current';
- }
- $zinc->scale($tag, .975, .975);
- $zinc->translate($tag, 1, 1);
-
- if ($zinc->find('withtag', "($tag && ico)")) {
- my $oldcolor = $zinc->itemcget("($tag && ico)", -fillcolor);
- $zinc->itemconfigure('ico', -fillcolor => '#000000');
-
- my $newcolor = ($oldcolor eq '#000000') ?'#ffff00' : '#000000';
- $zinc->itemconfigure("($tag && ico)", -fillcolor => $newcolor);
- }
-}
-
-#-----------------------------------------------------------------------------------
-# Callback sur evt RELEASE des items tagés 'pushbtn'
-#-----------------------------------------------------------------------------------
-sub pullButton {
- my $tag = ($zinc->itemcget('current', -tags))[0];
- $zinc->treset($tag);
-}
-
-
-#-----------------------------------------------------------------------------------
-# Callback sur evt CATCH des items tagés 'poly'
-# armement de rotation des polygones
-#-----------------------------------------------------------------------------------
-sub startRotatePolygone {
- my $ev = $zinc->XEvent;
- my ($xref, $yref) = $zinc->transform($zinc->group('current'), 1, [0, 0]);
- $previousangle = &lineAngle([$ev->x, $ev->y], [$xref, $yref]);
-}
-
-#-----------------------------------------------------------------------------------
-# Callback sur evt MOTION des items tagés 'poly'
-# rotation des polygones
-#-----------------------------------------------------------------------------------
-sub rotatePolygone {
- my $tag = ($zinc->itemcget('current', -tags))[0];
- my $ev = $zinc->XEvent;
- my ($xref, $yref) = $zinc->transform($zinc->group('current'), 1, [0, 0]);
- my $newangle = &lineAngle([$ev->x, $ev->y], [$xref, $yref]);
-
- $zinc->rotate($tag, deg2rad($newangle - $previousangle));
- $previousangle = $newangle;
-}
-
-#-----------------------------------------------------------------------------------
-# Callback CATCH de sélection (début de déplacement) des items tagés 'move'
-#-----------------------------------------------------------------------------------
-sub mobileStart {
- my $ev = $zinc->XEvent;
- ($dx, $dy) = (0 - $ev->x, 0 - $ev->y);
-
- $zinc->raise('current');
-
-}
-
-
-#-----------------------------------------------------------------------------------
-# Callback MOVE de déplacement des items tagés 'move'
-#-----------------------------------------------------------------------------------
-sub mobileMove {
- my $ev = $zinc->XEvent;
- $zinc->translate('current', $ev->x + $dx, $ev->y +$dy);
- ($dx, $dy) = (0 - $ev->x, 0 - $ev->y);
-
-}
-
-
-#-----------------------------------------------------------------------------------
-# Callback RELEASE de relaché (fin de déplacement) des items tagés 'move'
-#-----------------------------------------------------------------------------------
-sub mobileStop {
- &mobileMove;
-}
-
-
-#-----------------------------------------------------------------------------------
-# Callback sur evénément Tk <KeyPress> flèche gauche, haut, droite, bas
-# pan (translation) du contenu de la page active (TabBox)
-#-----------------------------------------------------------------------------------
-sub viewTranslate {
- my $way = shift;
-
- my $dx = ($way eq 'left') ? -10 : ($way eq 'right') ? 10 : 0;
- my $dy = ($way eq 'up') ? -10 : ($way eq 'down') ? 10 : 0;
-
- $zinc->translate($curview, $dx, $dy);
-
-}
-
-#-----------------------------------------------------------------------------------
-# Callback sur evénément Tk <KeyPress> "+" ou "-"
-# zoom du contenu de la page active (TabBox)
-#-----------------------------------------------------------------------------------
-sub viewZoom {
- my $key = shift;
- my $scaleratio = ($key eq 'up') ? 1+$zoomfactor : 1-$zoomfactor;
-
- $zinc->scale($curview, $scaleratio, $scaleratio);
-
-}
-
-
-#-----------------------------------------------------------------------------------
-# Callback sur evénément Tk <KeyPress> ">" ou "<"
-# rotation du contenu de la page active (TabBox)
-#-----------------------------------------------------------------------------------
-sub viewRotate {
- my $way = shift;
- my $delta_angle = $rotate_angle;
-
- $delta_angle *= -1 if ($way eq 'cw');
-
- $zinc->rotate($curview, $delta_angle);
-
-}
-
-
-
-1;
diff --git a/Perl/demos/Tk/demos/zinc_lib/textInput.pl b/Perl/demos/Tk/demos/zinc_lib/textInput.pl
deleted file mode 100644
index 414f613..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/textInput.pl
+++ /dev/null
@@ -1,98 +0,0 @@
-#!/usr/bin/perl -w
-# $Id$
-# This simple demo has been developped by C. Mertz <mertz@cena.fr>
-
-package textInput; # for avoiding symbol re-use between different demos
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-
-use Tk;
-use Tk::Zinc;
-use strict;
-
-use Tk::Zinc::Text; # the module for facilitating text input with zinc
-
-my $mw = MainWindow->new();
-
-###########################################
-# Text zone
-###########################################
-
-my $text = $mw->Text(-relief => 'sunken', -borderwidth => 2, -height => 4);
-$text->pack(qw/-expand yes -fill both/);
-
-$text->insert('0.0',
-'This toy-appli demonstrates the use of the
-Tk::Zinc::Text module. This module is designed for
-facilitating text input "a la emacs" on text items or on
-fields of items such as tracks, waypoints or tabulars.');
-
-
-###########################################
-# Zinc
-##########################################
-my $zinc = $mw->Zinc(-width => 500, -height => 300,
- -font => "10x20",
- -borderwidth => 3, -relief => 'sunken',
- )->pack;
-
-Tk::Zinc::Text->new ($zinc); # for mapping text input bindings on item with a 'text' tag.
-
-
-### creating a tabular with 3 fields, 2 of them being editable
-my $labelformat1 = "130x100 x130x20+0+0 x130x20+0+20 x130x20+0+40";
-
-my $x=120;
-my $y=6;
-my $track = $zinc->add('track',1, 3,
- -position => [$x,$y],
- -speedvector => [40, 10],
- -labeldistance => 30,
- -labelformat => $labelformat1,
- -tags => 'text',
- );
-# moving the track, to display past positions
-foreach my $i (0..5) { $zinc->coords("$track",[$x+$i*10,$y+$i*2]); }
-
-$zinc->itemconfigure($track, 0,
- -border => "contour",
- -text => "not editable",
- -sensitive => 0,
- );
-$zinc->itemconfigure($track, 1,
- -border => "contour",
- -text => "editable",
- -sensitive => 1,
- );
-$zinc->itemconfigure($track, 2,
- -border => "contour",
- -text => "editable too",
- -alignment => "center",
- -sensitive => 1,
- );
-
-# creating a text item, tagged with 'text', but not editable because
-# it is not sensitive
-$zinc->add('text', 1,
- -position => [220,160],
- -text => "this text is not
-editable because it is
-not sensitive",
- -sensitive => 0,
- -tags => ['text'],
- );
-
-# creating an editable text item
-$zinc->add('text', 1,
- -position => [50,230],
- -text => "this text IS
-editable",
- -sensitive => 1,
- -tags => ['text'],
- );
-
-
-
-Tk::MainLoop;
diff --git a/Perl/demos/Tk/demos/zinc_lib/tiger.pl b/Perl/demos/Tk/demos/zinc_lib/tiger.pl
deleted file mode 100644
index 4972d39..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/tiger.pl
+++ /dev/null
@@ -1,554 +0,0 @@
-#!/usr/bin/perl -w
-
-# $Id$
-# This simple demo has been developped by C. Mertz <mertz@intuilab.com>
-
-####### This file has been initially generated from tiger.svg by SVG2zinc.pm Version: Revision: 1.10
-### the idea of using the shape extension (as possible with TkZinc
-### under linux) was from Daniel Etienne! Thx!
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-
-use Tk::Zinc;
-use Tk::Zinc::Debug;
-
-my $mw = MainWindow->new();
-$mw->title('tiger generated from svg file');
-
-my ($WIDTH,$HEIGHT) = (600,600);
-my $zinc = $mw->Zinc(-width => $WIDTH, -height => $HEIGHT,
- -borderwidth => 0,
- -backcolor => "grey90",
- -render => 1,
- -reshape => 1,
- -fullreshape => 1,
- )->pack;
-
-
-&Tk::Zinc::Debug::init($zinc,
- -optionsToDisplay => '-tags',
- -optionsFormat => 'row',
- );
-
-my $top_group = $zinc->add('group', 1);
-
-$text = "
-Drag-Button 1 for moving the tiger,
-Drag-Button 2 for zooming the tiger,
-Drag-Button 3 for rotating the tiger,
-esc for getting help on Tk::Zinc::Debug functions.
-";
-
-my $clip= $zinc->add('curve',1,
- [ [0,150], [150,0], [470,20], [580, 200], [600,300], [500,560], [50,550], [10,450] ],
- -closed => 1, -visible => 0);
-
-$zinc->itemconfigure(1, -clip => $clip);
-
-$zinc->add('text', 1, -position => [51,521], -anchor => 'w',
- -priority => 20, -text => $text, -color => "white");
-$zinc->add('text', 1, -position => [50,520], -anchor => 'w',
- -priority => 20, -text => $text, -color => "black");
-
-$zinc->add('curve',$top_group,[[122.304, 84.285], [-122.304, 84.285, 'c'], [-122.203, 86.179, 'c'], [-123.027, 86.16], [-123.851, 86.141, 'c'], [-140.305, 38.066, 'c'], [-160.833, 40.309], [-160.833, 40.309, 'c'], [-143.05, 32.956, 'c'], [-122.304, 84.285]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.172);
-$zinc->add('curve',$top_group,[[118.774, 81.262], [-118.774, 81.262, 'c'], [-119.323, 83.078, 'c'], [-120.092, 82.779], [-120.86, 82.481, 'c'], [-119.977, 31.675, 'c'], [-140.043, 26.801], [-140.043, 26.801, 'c'], [-120.82, 25.937, 'c'], [-118.774, 81.262]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.172);
-$zinc->add('curve',$top_group,[[91.284, 123.59], [-91.284, 123.59, 'c'], [-89.648, 124.55, 'c'], [-90.118, 125.227], [-90.589, 125.904, 'c'], [-139.763, 113.102, 'c'], [-149.218, 131.459], [-149.218, 131.459, 'c'], [-145.539, 112.572, 'c'], [-91.284, 123.59]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.172);
-$zinc->add('curve',$top_group,[[94.093, 133.801], [-94.093, 133.801, 'c'], [-92.237, 134.197, 'c'], [-92.471, 134.988], [-92.704, 135.779, 'c'], [-143.407, 139.121, 'c'], [-146.597, 159.522], [-146.597, 159.522, 'c'], [-149.055, 140.437, 'c'], [-94.093, 133.801]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.172);
-$zinc->add('curve',$top_group,[[98.304, 128.276], [-98.304, 128.276, 'c'], [-96.526, 128.939, 'c'], [-96.872, 129.687], [-97.218, 130.435, 'c'], [-147.866, 126.346, 'c'], [-153.998, 146.064], [-153.998, 146.064, 'c'], [-153.646, 126.825, 'c'], [-98.304, 128.276]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.172);
-$zinc->add('curve',$top_group,[[109.009, 110.072], [-109.009, 110.072, 'c'], [-107.701, 111.446, 'c'], [-108.34, 111.967], [-108.979, 112.488, 'c'], [-152.722, 86.634, 'c'], [-166.869, 101.676], [-166.869, 101.676, 'c'], [-158.128, 84.533, 'c'], [-109.009, 110.072]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.172);
-$zinc->add('curve',$top_group,[[116.554, 114.263], [-116.554, 114.263, 'c'], [-115.098, 115.48, 'c'], [-115.674, 116.071], [-116.25, 116.661, 'c'], [-162.638, 95.922, 'c'], [-174.992, 112.469], [-174.992, 112.469, 'c'], [-168.247, 94.447, 'c'], [-116.554, 114.263]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.172);
-$zinc->add('curve',$top_group,[[119.154, 118.335], [-119.154, 118.335, 'c'], [-117.546, 119.343, 'c'], [-118.036, 120.006], [-118.526, 120.669, 'c'], [-167.308, 106.446, 'c'], [-177.291, 124.522], [-177.291, 124.522, 'c'], [-173.066, 105.749, 'c'], [-119.154, 118.335]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.172);
-$zinc->add('curve',$top_group,[[108.42, 118.949], [-108.42, 118.949, 'c'], [-107.298, 120.48, 'c'], [-107.999, 120.915], [-108.7, 121.35, 'c'], [-148.769, 90.102, 'c'], [-164.727, 103.207], [-164.727, 103.207, 'c'], [-153.862, 87.326, 'c'], [-108.42, 118.949]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.172);
-$zinc->add('curve',$top_group,[[128.2, 90], [-128.2, 90, 'c'], [-127.6, 91.8, 'c'], [-128.4, 92], [-129.2, 92.2, 'c'], [-157.8, 50.2, 'c'], [-177.001, 57.8], [-177.001, 57.8, 'c'], [-161.8, 46, 'c'], [-128.2, 90]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.172);
-$zinc->add('curve',$top_group,[[127.505, 96.979], [-127.505, 96.979, 'c'], [-126.53, 98.608, 'c'], [-127.269, 98.975], [-128.007, 99.343, 'c'], [-164.992, 64.499, 'c'], [-182.101, 76.061], [-182.101, 76.061, 'c'], [-169.804, 61.261, 'c'], [-127.505, 96.979]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.172);
-$zinc->add('curve',$top_group,[[127.62, 101.349], [-127.62, 101.349, 'c'], [-126.498, 102.88, 'c'], [-127.199, 103.315], [-127.9, 103.749, 'c'], [-167.969, 72.502, 'c'], [-183.927, 85.607], [-183.927, 85.607, 'c'], [-173.062, 69.726, 'c'], [-127.62, 101.349]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.172);
-$zinc->add('curve',$top_group,[[129.83, 103.065], [-129.327, 109.113, 'c'], [-128.339, 115.682, 'c'], [-126.6, 118.801], [-126.6, 118.801, 'c'], [-130.2, 131.201, 'c'], [-121.4, 144.401], [-121.4, 144.401, 'c'], [-121.8, 151.601, 'c'], [-120.2, 154.801], [-120.2, 154.801, 'c'], [-116.2, 163.201, 'c'], [-111.4, 164.001], [-107.516, 164.648, 'c'], [-98.793, 167.717, 'c'], [-88.932, 169.121], [-88.932, 169.121, 'c'], [-71.8, 183.201, 'c'], [-75, 196.001], [-75, 196.001, 'c'], [-75.4, 212.401, 'c'], [-79, 214.001], [-79, 214.001, 'c'], [-67.4, 202.801, 'c'], [-77, 219.601], [-81.4, 238.401], [-81.4, 238.401, 'c'], [-55.8, 216.801, 'c'], [-71.4, 235.201], [-81.4, 261.201], [-81.4, 261.201, 'c'], [-61.8, 242.801, 'c'], [-69, 251.201], [-72.2, 260.001], [-72.2, 260.001, 'c'], [-29, 232.801, 'c'], [-59.8, 262.401], [-59.8, 262.401, 'c'], [-51.8, 258.801, 'c'], [-47.4, 261.601], [-47.4, 261.601, 'c'], [-40.6, 260.401, 'c'], [-41.4, 262.001], [-41.4, 262.001, 'c'], [-62.2, 272.401, 'c'], [-65.8, 290.801], [-65.8, 290.801, 'c'], [-57.4, 280.801, 'c'], [-60.6, 291.601], [-60.2, 303.201], [-60.2, 303.201, 'c'], [-56.2, 281.601, 'c'], [-56.6, 319.201], [-56.6, 319.201, 'c'], [-37.4, 301.201, 'c'], [-49, 322.001], [-49, 338.801], [-49, 338.801, 'c'], [-33.8, 322.401, 'c'], [-40.2, 335.201], [-40.2, 335.201, 'c'], [-30.2, 326.401, 'c'], [-34.2, 341.601], [-34.2, 341.601, 'c'], [-35, 352.001, 'c'], [-30.6, 340.801], [-30.6, 340.801, 'c'], [-14.6, 310.201, 'c'], [-20.6, 336.401], [-20.6, 336.401, 'c'], [-21.4, 355.601, 'c'], [-16.6, 340.801], [-16.6, 340.801, 'c'], [-16.2, 351.201, 'c'], [-7, 358.401], [-7, 358.401, 'c'], [-8.2, 307.601, 'c'], [4.6, 343.601], [8.6, 360.001], [8.6, 360.001, 'c'], [11.4, 350.801, 'c'], [11, 345.601], [11, 345.601, 'c'], [25.8, 329.201, 'c'], [19, 353.601], [19, 353.601, 'c'], [34.2, 330.801, 'c'], [31, 344.001], [31, 344.001, 'c'], [23.4, 360.001, 'c'], [25, 364.801], [25, 364.801, 'c'], [41.8, 330.001, 'c'], [43, 328.401], [43, 328.401, 'c'], [41, 370.802, 'c'], [51.8, 334.801], [51.8, 334.801, 'c'], [57.4, 346.801, 'c'], [54.6, 351.201], [54.6, 351.201, 'c'], [62.6, 343.201, 'c'], [61.8, 340.001], [61.8, 340.001, 'c'], [66.4, 331.801, 'c'], [69.2, 345.401], [69.2, 345.401, 'c'], [71, 354.801, 'c'], [72.6, 351.601], [72.6, 351.601, 'c'], [76.6, 375.602, 'c'], [77.8, 352.801], [77.8, 352.801, 'c'], [79.4, 339.201, 'c'], [72.2, 327.601], [72.2, 327.601, 'c'], [73, 324.401, 'c'], [70.2, 320.401], [70.2, 320.401, 'c'], [83.8, 342.001, 'c'], [76.6, 313.201], [76.6, 313.201, 'c'], [87.801, 321.201, 'c'], [89.001, 321.201], [89.001, 321.201, 'c'], [75.4, 298.001, 'c'], [84.2, 302.801], [84.2, 302.801, 'c'], [79, 292.401, 'c'], [97.001, 304.401], [97.001, 304.401, 'c'], [81, 288.401, 'c'], [98.601, 298.001], [98.601, 298.001, 'c'], [106.601, 304.401, 'c'], [99.001, 294.401], [99.001, 294.401, 'c'], [84.6, 278.401, 'c'], [106.601, 296.401], [106.601, 296.401, 'c'], [118.201, 312.801, 'c'], [119.001, 315.601], [119.001, 315.601, 'c'], [109.001, 286.401, 'c'], [104.601, 283.601], [104.601, 283.601, 'c'], [113.001, 247.201, 'c'], [154.201, 262.801], [154.201, 262.801, 'c'], [161.001, 280.001, 'c'], [165.401, 261.601], [165.401, 261.601, 'c'], [178.201, 255.201, 'c'], [189.401, 282.801], [189.401, 282.801, 'c'], [193.401, 269.201, 'c'], [192.601, 266.401], [192.601, 266.401, 'c'], [199.401, 267.601, 'c'], [198.601, 266.401], [198.601, 266.401, 'c'], [211.801, 270.801, 'c'], [213.001, 270.001], [213.001, 270.001, 'c'], [219.801, 276.801, 'c'], [220.201, 273.201], [220.201, 273.201, 'c'], [229.401, 276.001, 'c'], [227.401, 272.401], [227.401, 272.401, 'c'], [236.201, 288.001, 'c'], [236.601, 291.601], [239.001, 277.601], [241.001, 280.401], [241.001, 280.401, 'c'], [242.601, 272.801, 'c'], [241.801, 271.601], [241.001, 270.401, 'c'], [261.801, 278.401, 'c'], [266.601, 299.201], [268.601, 307.601], [268.601, 307.601, 'c'], [274.601, 292.801, 'c'], [273.001, 288.801], [273.001, 288.801, 'c'], [278.201, 289.601, 'c'], [278.601, 294.001], [278.601, 294.001, 'c'], [282.601, 270.801, 'c'], [277.801, 264.801], [277.801, 264.801, 'c'], [282.201, 264.001, 'c'], [283.401, 267.601], [283.401, 260.401], [283.401, 260.401, 'c'], [290.601, 261.201, 'c'], [290.601, 258.801], [290.601, 258.801, 'c'], [295.001, 254.801, 'c'], [297.001, 259.601], [297.001, 259.601, 'c'], [284.601, 224.401, 'c'], [303.001, 243.601], [303.001, 243.601, 'c'], [310.201, 254.401, 'c'], [306.601, 235.601], [303.001, 216.801, 'c'], [299.001, 215.201, 'c'], [303.801, 214.801], [303.801, 214.801, 'c'], [304.601, 211.201, 'c'], [302.601, 209.601], [300.601, 208.001, 'c'], [303.801, 209.601, 'c'], [303.801, 209.601], [303.801, 209.601, 'c'], [308.601, 213.601, 'c'], [303.401, 191.601], [303.401, 191.601, 'c'], [309.801, 193.201, 'c'], [297.801, 164.001], [297.801, 164.001, 'c'], [300.601, 161.601, 'c'], [296.601, 153.201], [296.601, 153.201, 'c'], [304.601, 157.601, 'c'], [307.401, 156.001], [307.401, 156.001, 'c'], [307.001, 154.401, 'c'], [303.801, 150.401], [303.801, 150.401, 'c'], [282.201, 95.6, 'c'], [302.601, 117.601], [302.601, 117.601, 'c'], [314.451, 131.151, 'c'], [308.051, 108.351], [308.051, 108.351, 'c'], [298.94, 84.341, 'c'], [299.717, 80.045], [-129.83, 103.065]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1);
-$zinc->add('curve',$top_group,[[299.717, 80.245], [300.345, 80.426, 'c'], [302.551, 81.55, 'c'], [303.801, 83.2], [303.801, 83.2, 'c'], [310.601, 94, 'c'], [305.401, 75.6], [305.401, 75.6, 'c'], [296.201, 46.8, 'c'], [305.001, 58], [305.001, 58, 'c'], [311.001, 65.2, 'c'], [307.801, 51.6], [303.936, 35.173, 'c'], [301.401, 28.8, 'c'], [301.401, 28.8], [301.401, 28.8, 'c'], [313.001, 33.6, 'c'], [286.201, -6], [295.001, -2.4], [295.001, -2.4, 'c'], [275.401, -42, 'c'], [253.801, -47.2], [245.801, -53.2], [245.801, -53.2, 'c'], [284.201, -91.2, 'c'], [271.401, -128], [271.401, -128, 'c'], [264.601, -133.2, 'c'], [255.001, -124], [255.001, -124, 'c'], [248.601, -119.2, 'c'], [242.601, -120.8], [242.601, -120.8, 'c'], [211.801, -119.6, 'c'], [209.801, -119.6], [207.801, -119.6, 'c'], [173.001, -156.8, 'c'], [107.401, -139.2], [107.401, -139.2, 'c'], [102.201, -137.2, 'c'], [97.801, -138.4], [97.801, -138.4, 'c'], [79.4, -154.4, 'c'], [30.6, -131.6], [30.6, -131.6, 'c'], [20.6, -129.6, 'c'], [19, -129.6], [17.4, -129.6, 'c'], [14.6, -129.6, 'c'], [6.6, -123.2], [-1.4, -116.8, 'c'], [-1.8, -116, 'c'], [-3.8, -114.4], [-3.8, -114.4, 'c'], [-20.2, -103.2, 'c'], [-25, -102.4], [-25, -102.4, 'c'], [-36.6, -96, 'c'], [-41, -86], [-44.6, -84.8], [-44.6, -84.8, 'c'], [-46.2, -77.6, 'c'], [-46.6, -76.4], [-46.6, -76.4, 'c'], [-51.4, -72.8, 'c'], [-52.2, -67.2], [-52.2, -67.2, 'c'], [-61, -61.2, 'c'], [-60.6, -56.8], [-60.6, -56.8, 'c'], [-62.2, -51.6, 'c'], [-63, -46.8], [-63, -46.8, 'c'], [-70.2, -42, 'c'], [-69.4, -39.2], [-69.4, -39.2, 'c'], [-77, -25.2, 'c'], [-75.8, -18.4], [-75.8, -18.4, 'c'], [-82.2, -18.8, 'c'], [-85, -16.4], [-85, -16.4, 'c'], [-85.8, -11.6, 'c'], [-87.4, -11.2], [-87.4, -11.2, 'c'], [-90.2, -10, 'c'], [-87.8, -6], [-87.8, -6, 'c'], [-89.4, -3.2, 'c'], [-89.8, -1.6], [-89.8, -1.6, 'c'], [-89, 1.2, 'c'], [-93.4, 6.8], [-93.4, 6.8, 'c'], [-99.8, 25.6, 'c'], [-97.8, 30.8], [-97.8, 30.8, 'c'], [-97.4, 35.6, 'c'], [-100.2, 37.2], [-100.2, 37.2, 'c'], [-103.8, 36.8, 'c'], [-95.4, 48.8], [-95.4, 48.8, 'c'], [-94.6, 50, 'c'], [-97.8, 52.4], [-97.8, 52.4, 'c'], [-115, 56, 'c'], [-117.4, 72.4], [-117.4, 72.4, 'c'], [-131, 87.2, 'c'], [-131, 92.4], [-131, 94.705, 'c'], [-130.729, 97.852, 'c'], [-130.03, 102.465], [-130.03, 102.465, 'c'], [-130.6, 110.801, 'c'], [-103, 111.601], [-75.4, 112.401, 'c'], [299.717, 80.245, 'c'], [299.717, 80.245]], -closed => 1, -linecolor => "#000000", -fillcolor => "#cc7226", -filled => 1);
-
-$zinc->add('curve',$top_group,[[115.6, 102.6], [-140.6, 63.2, 'c'], [-126.2, 119.601, 'c'], [-126.2, 119.601], [-117.4, 154.001, 'c'], [12.2, 116.401, 'c'], [12.2, 116.401], [12.2, 116.401, 'c'], [181.001, 86, 'c'], [192.201, 82], [203.401, 78, 'c'], [298.601, 84.4, 'c'], [298.601, 84.4], [293.001, 67.6], [228.201, 21.2, 'c'], [209.001, 44.4, 'c'], [195.401, 40.4], [181.801, 36.4, 'c'], [184.201, 46, 'c'], [181.001, 46.8], [177.801, 47.6, 'c'], [138.601, 22.8, 'c'], [132.201, 23.6], [125.801, 24.4, 'c'], [100.459, 0.649, 'c'], [115.401, 32.4], [131.401, 66.4, 'c'], [57, 71.6, 'c'], [40.2, 60.4], [23.4, 49.2, 'c'], [47.4, 78.8, 'c'], [47.4, 78.8], [65.8, 98.8, 'c'], [31.4, 82, 'c'], [31.4, 82], [-3, 69.2, 'c'], [-27, 94.8, 'c'], [-30.2, 95.6], [-33.4, 96.4, 'c'], [-38.2, 99.6, 'c'], [-39, 93.2], [-39.8, 86.8, 'c'], [-47.31, 70.099, 'c'], [-79, 96.4], [-99, 113.001, 'c'], [-112.8, 91, 'c'], [-112.8, 91], [-115.6, 102.6]], -closed => 1, -fillcolor => "#cc7226", -filled => 1, -linecolor => "#cc7226");
-$zinc->add('curve',$top_group,[[133.51, 25.346], [127.11, 26.146, 'c'], [101.743, 2.407, 'c'], [116.71, 34.146], [133.31, 69.346, 'c'], [58.31, 73.346, 'c'], [41.51, 62.146], [24.709, 50.946, 'c'], [48.71, 80.546, 'c'], [48.71, 80.546], [67.11, 100.546, 'c'], [32.709, 83.746, 'c'], [32.709, 83.746], [-1.691, 70.946, 'c'], [-25.691, 96.546, 'c'], [-28.891, 97.346], [-32.091, 98.146, 'c'], [-36.891, 101.346, 'c'], [-37.691, 94.946], [-38.491, 88.546, 'c'], [-45.87, 72.012, 'c'], [-77.691, 98.146], [-98.927, 115.492, 'c'], [-112.418, 94.037, 'c'], [-112.418, 94.037], [-115.618, 104.146], [-140.618, 64.346, 'c'], [-125.546, 122.655, 'c'], [-125.546, 122.655], [-116.745, 157.056, 'c'], [13.509, 118.146, 'c'], [13.509, 118.146], [13.509, 118.146, 'c'], [182.31, 87.746, 'c'], [193.51, 83.746], [204.71, 79.746, 'c'], [299.038, 86.073, 'c'], [299.038, 86.073], [293.51, 68.764], [228.71, 22.364, 'c'], [210.31, 46.146, 'c'], [196.71, 42.146], [183.11, 38.146, 'c'], [185.51, 47.746, 'c'], [182.31, 48.546], [179.11, 49.346, 'c'], [139.91, 24.546, 'c'], [133.51, 25.346]], -closed => 1, -fillcolor => "#e87f3a", -filled => 1, -linecolor => "#e87f3a");
-$zinc->add('curve',$top_group,[[134.819, 27.091], [128.419, 27.891, 'c'], [103.685, 3.862, 'c'], [118.019, 35.891], [134.219, 72.092, 'c'], [59.619, 75.092, 'c'], [42.819, 63.892], [26.019, 52.692, 'c'], [50.019, 82.292, 'c'], [50.019, 82.292], [68.419, 102.292, 'c'], [34.019, 85.492, 'c'], [34.019, 85.492], [-0.381, 72.692, 'c'], [-24.382, 98.292, 'c'], [-27.582, 99.092], [-30.782, 99.892, 'c'], [-35.582, 103.092, 'c'], [-36.382, 96.692], [-37.182, 90.292, 'c'], [-44.43, 73.925, 'c'], [-76.382, 99.892], [-98.855, 117.983, 'c'], [-112.036, 97.074, 'c'], [-112.036, 97.074], [-115.636, 105.692], [-139.436, 66.692, 'c'], [-124.891, 125.71, 'c'], [-124.891, 125.71], [-116.091, 160.11, 'c'], [14.819, 119.892, 'c'], [14.819, 119.892], [14.819, 119.892, 'c'], [183.619, 89.492, 'c'], [194.819, 85.492], [206.019, 81.492, 'c'], [299.474, 87.746, 'c'], [299.474, 87.746], [294.02, 69.928], [229.219, 23.528, 'c'], [211.619, 47.891, 'c'], [198.019, 43.891], [184.419, 39.891, 'c'], [186.819, 49.491, 'c'], [183.619, 50.292], [180.419, 51.092, 'c'], [141.219, 26.291, 'c'], [134.819, 27.091]], -closed => 1, -fillcolor => "#ea8c4d", -filled => 1, -linecolor => "#ea8c4d");
-$zinc->add('curve',$top_group,[[136.128, 28.837], [129.728, 29.637, 'c'], [104.999, 5.605, 'c'], [119.328, 37.637], [136.128, 75.193, 'c'], [60.394, 76.482, 'c'], [44.128, 65.637], [27.328, 54.437, 'c'], [51.328, 84.037, 'c'], [51.328, 84.037], [69.728, 104.037, 'c'], [35.328, 87.237, 'c'], [35.328, 87.237], [0.928, 74.437, 'c'], [-23.072, 100.037, 'c'], [-26.272, 100.837], [-29.472, 101.637, 'c'], [-34.272, 104.837, 'c'], [-35.072, 98.437], [-35.872, 92.037, 'c'], [-42.989, 75.839, 'c'], [-75.073, 101.637], [-98.782, 120.474, 'c'], [-111.655, 100.11, 'c'], [-111.655, 100.11], [-115.655, 107.237], [-137.455, 70.437, 'c'], [-124.236, 128.765, 'c'], [-124.236, 128.765], [-115.436, 163.165, 'c'], [16.128, 121.637, 'c'], [16.128, 121.637], [16.128, 121.637, 'c'], [184.928, 91.237, 'c'], [196.129, 87.237], [207.329, 83.237, 'c'], [299.911, 89.419, 'c'], [299.911, 89.419], [294.529, 71.092], [229.729, 24.691, 'c'], [212.929, 49.637, 'c'], [199.329, 45.637], [185.728, 41.637, 'c'], [188.128, 51.237, 'c'], [184.928, 52.037], [181.728, 52.837, 'c'], [142.528, 28.037, 'c'], [136.128, 28.837]], -closed => 1, -fillcolor => "#ec9961", -filled => 1, -linecolor => "#ec9961");
-$zinc->add('curve',$top_group,[[137.438, 30.583], [131.037, 31.383, 'c'], [106.814, 7.129, 'c'], [120.637, 39.383], [137.438, 78.583, 'c'], [62.237, 78.583, 'c'], [45.437, 67.383], [28.637, 56.183, 'c'], [52.637, 85.783, 'c'], [52.637, 85.783], [71.037, 105.783, 'c'], [36.637, 88.983, 'c'], [36.637, 88.983], [2.237, 76.183, 'c'], [-21.763, 101.783, 'c'], [-24.963, 102.583], [-28.163, 103.383, 'c'], [-32.963, 106.583, 'c'], [-33.763, 100.183], [-34.563, 93.783, 'c'], [-41.548, 77.752, 'c'], [-73.763, 103.383], [-98.709, 122.965, 'c'], [-111.273, 103.146, 'c'], [-111.273, 103.146], [-115.673, 108.783], [-135.473, 73.982, 'c'], [-123.582, 131.819, 'c'], [-123.582, 131.819], [-114.782, 166.22, 'c'], [17.437, 123.383, 'c'], [17.437, 123.383], [17.437, 123.383, 'c'], [186.238, 92.983, 'c'], [197.438, 88.983], [208.638, 84.983, 'c'], [300.347, 91.092, 'c'], [300.347, 91.092], [295.038, 72.255], [230.238, 25.855, 'c'], [214.238, 51.383, 'c'], [200.638, 47.383], [187.038, 43.383, 'c'], [189.438, 52.983, 'c'], [186.238, 53.783], [183.038, 54.583, 'c'], [143.838, 29.783, 'c'], [137.438, 30.583]], -closed => 1, -fillcolor => "#eea575", -filled => 1, -linecolor => "#eea575");
-$zinc->add('curve',$top_group,[[138.747, 32.328], [132.347, 33.128, 'c'], [106.383, 9.677, 'c'], [121.947, 41.128], [141.147, 79.928, 'c'], [63.546, 80.328, 'c'], [46.746, 69.128], [29.946, 57.928, 'c'], [53.946, 87.528, 'c'], [53.946, 87.528], [72.346, 107.528, 'c'], [37.946, 90.728, 'c'], [37.946, 90.728], [3.546, 77.928, 'c'], [-20.454, 103.528, 'c'], [-23.654, 104.328], [-26.854, 105.128, 'c'], [-31.654, 108.328, 'c'], [-32.454, 101.928], [-33.254, 95.528, 'c'], [-40.108, 79.665, 'c'], [-72.454, 105.128], [-98.636, 125.456, 'c'], [-110.891, 106.183, 'c'], [-110.891, 106.183], [-115.691, 110.328], [-133.691, 77.128, 'c'], [-122.927, 134.874, 'c'], [-122.927, 134.874], [-114.127, 169.274, 'c'], [18.746, 125.128, 'c'], [18.746, 125.128], [18.746, 125.128, 'c'], [187.547, 94.728, 'c'], [198.747, 90.728], [209.947, 86.728, 'c'], [300.783, 92.764, 'c'], [300.783, 92.764], [295.547, 73.419], [230.747, 27.019, 'c'], [215.547, 53.128, 'c'], [201.947, 49.128], [188.347, 45.128, 'c'], [190.747, 54.728, 'c'], [187.547, 55.528], [184.347, 56.328, 'c'], [145.147, 31.528, 'c'], [138.747, 32.328]], -closed => 1, -fillcolor => "#f1b288", -filled => 1, -linecolor => "#f1b288");
-$zinc->add('curve',$top_group,[[140.056, 34.073], [133.655, 34.873, 'c'], [107.313, 11.613, 'c'], [123.255, 42.873], [143.656, 82.874, 'c'], [64.855, 82.074, 'c'], [48.055, 70.874], [31.255, 59.674, 'c'], [55.255, 89.274, 'c'], [55.255, 89.274], [73.655, 109.274, 'c'], [39.255, 92.474, 'c'], [39.255, 92.474], [4.855, 79.674, 'c'], [-19.145, 105.274, 'c'], [-22.345, 106.074], [-25.545, 106.874, 'c'], [-30.345, 110.074, 'c'], [-31.145, 103.674], [-31.945, 97.274, 'c'], [-38.668, 81.578, 'c'], [-71.145, 106.874], [-98.564, 127.947, 'c'], [-110.509, 109.219, 'c'], [-110.509, 109.219], [-115.709, 111.874], [-131.709, 81.674, 'c'], [-122.273, 137.929, 'c'], [-122.273, 137.929], [-113.473, 172.329, 'c'], [20.055, 126.874, 'c'], [20.055, 126.874], [20.055, 126.874, 'c'], [188.856, 96.474, 'c'], [200.056, 92.474], [211.256, 88.474, 'c'], [301.22, 94.437, 'c'], [301.22, 94.437], [296.056, 74.583], [231.256, 28.183, 'c'], [216.856, 54.874, 'c'], [203.256, 50.874], [189.656, 46.873, 'c'], [192.056, 56.474, 'c'], [188.856, 57.274], [185.656, 58.074, 'c'], [146.456, 33.273, 'c'], [140.056, 34.073]], -closed => 1, -fillcolor => "#f3bf9c", -filled => 1, -linecolor => "#f3bf9c");
-$zinc->add('curve',$top_group,[[141.365, 35.819], [134.965, 36.619, 'c'], [107.523, 13.944, 'c'], [124.565, 44.619], [146.565, 84.219, 'c'], [66.164, 83.819, 'c'], [49.364, 72.619], [32.564, 61.419, 'c'], [56.564, 91.019, 'c'], [56.564, 91.019], [74.964, 111.019, 'c'], [40.564, 94.219, 'c'], [40.564, 94.219], [6.164, 81.419, 'c'], [-17.836, 107.019, 'c'], [-21.036, 107.819], [-24.236, 108.619, 'c'], [-29.036, 111.819, 'c'], [-29.836, 105.419], [-30.636, 99.019, 'c'], [-37.227, 83.492, 'c'], [-69.836, 108.619], [-98.491, 130.438, 'c'], [-110.127, 112.256, 'c'], [-110.127, 112.256], [-115.727, 113.419], [-130.128, 85.019, 'c'], [-121.618, 140.983, 'c'], [-121.618, 140.983], [-112.818, 175.384, 'c'], [21.364, 128.619, 'c'], [21.364, 128.619], [21.364, 128.619, 'c'], [190.165, 98.219, 'c'], [201.365, 94.219], [212.565, 90.219, 'c'], [301.656, 96.11, 'c'], [301.656, 96.11], [296.565, 75.746], [231.765, 29.346, 'c'], [218.165, 56.619, 'c'], [204.565, 52.619], [190.965, 48.619, 'c'], [193.365, 58.219, 'c'], [190.165, 59.019], [186.965, 59.819, 'c'], [147.765, 35.019, 'c'], [141.365, 35.819]], -closed => 1, -fillcolor => "#f5ccb0", -filled => 1, -linecolor => "#f5ccb0");
-$zinc->add('curve',$top_group,[[142.674, 37.565], [136.274, 38.365, 'c'], [108.832, 15.689, 'c'], [125.874, 46.365], [147.874, 85.965, 'c'], [67.474, 85.565, 'c'], [50.674, 74.365], [33.874, 63.165, 'c'], [57.874, 92.765, 'c'], [57.874, 92.765], [76.274, 112.765, 'c'], [41.874, 95.965, 'c'], [41.874, 95.965], [7.473, 83.165, 'c'], [-16.527, 108.765, 'c'], [-19.727, 109.565], [-22.927, 110.365, 'c'], [-27.727, 113.565, 'c'], [-28.527, 107.165], [-29.327, 100.765, 'c'], [-35.786, 85.405, 'c'], [-68.527, 110.365], [-98.418, 132.929, 'c'], [-109.745, 115.293, 'c'], [-109.745, 115.293], [-115.745, 114.965], [-129.346, 88.564, 'c'], [-120.963, 144.038, 'c'], [-120.963, 144.038], [-112.163, 178.438, 'c'], [22.673, 130.365, 'c'], [22.673, 130.365], [22.673, 130.365, 'c'], [191.474, 99.965, 'c'], [202.674, 95.965], [213.874, 91.965, 'c'], [302.093, 97.783, 'c'], [302.093, 97.783], [297.075, 76.91], [232.274, 30.51, 'c'], [219.474, 58.365, 'c'], [205.874, 54.365], [192.274, 50.365, 'c'], [194.674, 59.965, 'c'], [191.474, 60.765], [188.274, 61.565, 'c'], [149.074, 36.765, 'c'], [142.674, 37.565]], -closed => 1, -fillcolor => "#f8d8c4", -filled => 1, -linecolor => "#f8d8c4");
-$zinc->add('curve',$top_group,[[143.983, 39.31], [137.583, 40.11, 'c'], [110.529, 17.223, 'c'], [127.183, 48.11], [149.183, 88.91, 'c'], [68.783, 87.31, 'c'], [51.983, 76.11], [35.183, 64.91, 'c'], [59.183, 94.51, 'c'], [59.183, 94.51], [77.583, 114.51, 'c'], [43.183, 97.71, 'c'], [43.183, 97.71], [8.783, 84.91, 'c'], [-15.217, 110.51, 'c'], [-18.417, 111.31], [-21.618, 112.11, 'c'], [-26.418, 115.31, 'c'], [-27.218, 108.91], [-28.018, 102.51, 'c'], [-34.346, 87.318, 'c'], [-67.218, 112.11], [-98.345, 135.42, 'c'], [-109.363, 118.329, 'c'], [-109.363, 118.329], [-115.764, 116.51], [-128.764, 92.51, 'c'], [-120.309, 147.093, 'c'], [-120.309, 147.093], [-111.509, 181.493, 'c'], [23.983, 132.11, 'c'], [23.983, 132.11], [23.983, 132.11, 'c'], [192.783, 101.71, 'c'], [203.983, 97.71], [215.183, 93.71, 'c'], [302.529, 99.456, 'c'], [302.529, 99.456], [297.583, 78.074], [232.783, 31.673, 'c'], [220.783, 60.11, 'c'], [207.183, 56.11], [193.583, 52.11, 'c'], [195.983, 61.71, 'c'], [192.783, 62.51], [189.583, 63.31, 'c'], [150.383, 38.51, 'c'], [143.983, 39.31]], -closed => 1, -fillcolor => "#fae5d7", -filled => 1, -linecolor => "#fae5d7");
-$zinc->add('curve',$top_group,[[145.292, 41.055], [138.892, 41.855, 'c'], [112.917, 18.411, 'c'], [128.492, 49.855], [149.692, 92.656, 'c'], [70.092, 89.056, 'c'], [53.292, 77.856], [36.492, 66.656, 'c'], [60.492, 96.256, 'c'], [60.492, 96.256], [78.892, 116.256, 'c'], [44.492, 99.456, 'c'], [44.492, 99.456], [10.092, 86.656, 'c'], [-13.908, 112.256, 'c'], [-17.108, 113.056], [-20.308, 113.856, 'c'], [-25.108, 117.056, 'c'], [-25.908, 110.656], [-26.708, 104.256, 'c'], [-32.905, 89.232, 'c'], [-65.908, 113.856], [-98.273, 137.911, 'c'], [-108.982, 121.365, 'c'], [-108.982, 121.365], [-115.782, 118.056], [-128.582, 94.856, 'c'], [-119.654, 150.147, 'c'], [-119.654, 150.147], [-110.854, 184.547, 'c'], [25.292, 133.856, 'c'], [25.292, 133.856], [25.292, 133.856, 'c'], [194.093, 103.456, 'c'], [205.293, 99.456], [216.493, 95.456, 'c'], [302.965, 101.128, 'c'], [302.965, 101.128], [298.093, 79.237], [233.292, 32.837, 'c'], [222.093, 61.856, 'c'], [208.493, 57.856], [194.893, 53.855, 'c'], [197.293, 63.456, 'c'], [194.093, 64.256], [190.892, 65.056, 'c'], [151.692, 40.255, 'c'], [145.292, 41.055]], -closed => 1, -fillcolor => "#fcf2eb", -filled => 1, -linecolor => "#fcf2eb");
-$zinc->add('curve',$top_group,[[115.8, 119.601], [-128.6, 97.6, 'c'], [-119, 153.201, 'c'], [-119, 153.201], [-110.2, 187.601, 'c'], [26.6, 135.601, 'c'], [26.6, 135.601], [26.6, 135.601, 'c'], [195.401, 105.2, 'c'], [206.601, 101.2], [217.801, 97.2, 'c'], [303.401, 102.8, 'c'], [303.401, 102.8], [298.601, 80.4], [233.801, 34, 'c'], [223.401, 63.6, 'c'], [209.801, 59.6], [196.201, 55.6, 'c'], [198.601, 65.2, 'c'], [195.401, 66], [192.201, 66.8, 'c'], [153.001, 42, 'c'], [146.601, 42.8], [140.201, 43.6, 'c'], [114.981, 19.793, 'c'], [129.801, 51.6], [152.028, 99.307, 'c'], [69.041, 89.227, 'c'], [54.6, 79.6], [37.8, 68.4, 'c'], [61.8, 98, 'c'], [61.8, 98], [80.2, 118.001, 'c'], [45.8, 101.2, 'c'], [45.8, 101.2], [11.4, 88.4, 'c'], [-12.6, 114.001, 'c'], [-15.8, 114.801], [-19, 115.601, 'c'], [-23.8, 118.801, 'c'], [-24.6, 112.401], [-25.4, 106, 'c'], [-31.465, 91.144, 'c'], [-64.6, 115.601], [-98.2, 140.401, 'c'], [-108.6, 124.401, 'c'], [-108.6, 124.401], [-115.8, 119.601]], -closed => 1, -fillcolor => "#ffffff", -filled => 1, -linecolor => "#ffffff");
-$zinc->add('curve',$top_group,[[74.2, 149.601], [-74.2, 149.601, 'c'], [-81.4, 161.201, 'c'], [-60.6, 174.401], [-60.6, 174.401, 'c'], [-59.2, 175.801, 'c'], [-77.2, 171.601], [-77.2, 171.601, 'c'], [-83.4, 169.601, 'c'], [-85, 159.201], [-85, 159.201, 'c'], [-89.8, 154.801, 'c'], [-94.6, 149.201], [-99.4, 143.601, 'c'], [-74.2, 149.601, 'c'], [-74.2, 149.601]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-$zinc->add('curve',$top_group,[[65.8, 102], [65.8, 102, 'c'], [83.498, 128.821, 'c'], [82.9, 133.601], [81.6, 144.001, 'c'], [81.4, 153.601, 'c'], [84.6, 157.601], [87.801, 161.601, 'c'], [96.601, 194.801, 'c'], [96.601, 194.801], [96.601, 194.801, 'c'], [96.201, 196.001, 'c'], [108.601, 158.001], [108.601, 158.001, 'c'], [120.201, 142.001, 'c'], [100.201, 123.601], [100.201, 123.601, 'c'], [65, 94.8, 'c'], [65.8, 102]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-$zinc->add('curve',$top_group,[[54.2, 176.401], [-54.2, 176.401, 'c'], [-43, 183.601, 'c'], [-57.4, 214.801], [-51, 212.401], [-51, 212.401, 'c'], [-51.8, 223.601, 'c'], [-55, 226.001], [-47.8, 222.801], [-47.8, 222.801, 'c'], [-43, 230.801, 'c'], [-47, 235.601], [-47, 235.601, 'c'], [-30.2, 243.601, 'c'], [-31, 250.001], [-31, 250.001, 'c'], [-24.6, 242.001, 'c'], [-28.6, 235.601], [-32.6, 229.201, 'c'], [-39.8, 233.201, 'c'], [-39, 214.801], [-47.8, 218.001], [-47.8, 218.001, 'c'], [-42.2, 209.201, 'c'], [-42.2, 202.801], [-50.2, 205.201], [-50.2, 205.201, 'c'], [-34.731, 178.623, 'c'], [-45.4, 177.201], [-51.4, 176.401, 'c'], [-54.2, 176.401, 'c'], [-54.2, 176.401]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-$zinc->add('curve',$top_group,[[21.8, 193.201], [-21.8, 193.201, 'c'], [-19, 188.801, 'c'], [-21.8, 189.601], [-24.6, 190.401, 'c'], [-55.8, 205.201, 'c'], [-61.8, 214.801], [-61.8, 214.801, 'c'], [-27.4, 190.401, 'c'], [-21.8, 193.201]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-$zinc->add('curve',$top_group,[[11.4, 201.201], [-11.4, 201.201, 'c'], [-8.6, 196.801, 'c'], [-11.4, 197.601], [-14.2, 198.401, 'c'], [-45.4, 213.201, 'c'], [-51.4, 222.801], [-51.4, 222.801, 'c'], [-17, 198.401, 'c'], [-11.4, 201.201]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-$zinc->add('curve',$top_group,[[1.8, 186.001], [1.8, 186.001, 'c'], [4.6, 181.601, 'c'], [1.8, 182.401], [-1, 183.201, 'c'], [-32.2, 198.001, 'c'], [-38.2, 207.601], [-38.2, 207.601, 'c'], [-3.8, 183.201, 'c'], [1.8, 186.001]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-$zinc->add('curve',$top_group,[[21.4, 229.601], [-21.4, 229.601, 'c'], [-21.4, 223.601, 'c'], [-24.2, 224.401], [-27, 225.201, 'c'], [-63, 242.801, 'c'], [-69, 252.401], [-69, 252.401, 'c'], [-27, 226.801, 'c'], [-21.4, 229.601]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-$zinc->add('curve',$top_group,[[20.2, 218.801], [-20.2, 218.801, 'c'], [-19, 214.001, 'c'], [-21.8, 214.801], [-23.8, 214.801, 'c'], [-50.2, 226.401, 'c'], [-56.2, 236.001], [-56.2, 236.001, 'c'], [-26.6, 214.401, 'c'], [-20.2, 218.801]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-$zinc->add('curve',$top_group,[[34.6, 266.401], [-44.6, 274.001], [-44.6, 274.001, 'c'], [-34.2, 266.401, 'c'], [-30.6, 267.601], [-30.6, 267.601, 'c'], [-37.4, 278.801, 'c'], [-38.2, 284.001], [-38.2, 284.001, 'c'], [-27.8, 271.201, 'c'], [-22.2, 271.601], [-22.2, 271.601, 'c'], [-14.6, 272.001, 'c'], [-14.6, 282.801], [-14.6, 282.801, 'c'], [-9, 272.401, 'c'], [-5.8, 272.801], [-5.8, 272.801, 'c'], [-4.6, 279.201, 'c'], [-5.8, 286.001], [-5.8, 286.001, 'c'], [-1.8, 278.401, 'c'], [2.2, 280.001], [2.2, 280.001, 'c'], [8.6, 278.001, 'c'], [7.8, 289.601], [7.8, 289.601, 'c'], [7.8, 300.001, 'c'], [7, 302.801], [7, 302.801, 'c'], [12.6, 276.401, 'c'], [15, 276.001], [15, 276.001, 'c'], [23, 274.801, 'c'], [27.8, 283.601], [27.8, 283.601, 'c'], [23.8, 276.001, 'c'], [28.6, 278.001], [28.6, 278.001, 'c'], [39.4, 279.601, 'c'], [42.6, 286.401], [42.6, 286.401, 'c'], [35.8, 274.401, 'c'], [41.4, 277.601], [41.4, 277.601, 'c'], [48.2, 277.601, 'c'], [49.4, 284.001], [49.4, 284.001, 'c'], [57.8, 305.201, 'c'], [59.8, 306.801], [59.8, 306.801, 'c'], [52.2, 285.201, 'c'], [53.8, 285.201], [53.8, 285.201, 'c'], [51.8, 273.201, 'c'], [57, 288.001], [57, 288.001, 'c'], [53.8, 274.001, 'c'], [59.4, 274.801], [65, 275.601, 'c'], [69.4, 285.601, 'c'], [77.8, 283.201], [77.8, 283.201, 'c'], [87.401, 288.801, 'c'], [89.401, 219.601], [-34.6, 266.401]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-$zinc->add('curve',$top_group,[[29.8, 173.601], [-29.8, 173.601, 'c'], [-15, 167.601, 'c'], [25, 173.601], [25, 173.601, 'c'], [32.2, 174.001, 'c'], [39, 165.201], [45.8, 156.401, 'c'], [72.6, 149.201, 'c'], [79, 151.201], [88.601, 157.601], [89.401, 158.801], [89.401, 158.801, 'c'], [101.801, 169.201, 'c'], [102.201, 176.801], [102.601, 184.401, 'c'], [87.801, 232.401, 'c'], [78.2, 248.401], [68.6, 264.401, 'c'], [59, 276.801, 'c'], [39.8, 274.401], [39.8, 274.401, 'c'], [19, 270.401, 'c'], [-6.6, 274.401], [-6.6, 274.401, 'c'], [-35.8, 272.801, 'c'], [-38.6, 264.801], [-41.4, 256.801, 'c'], [-27.4, 241.601, 'c'], [-27.4, 241.601], [-27.4, 241.601, 'c'], [-23, 233.201, 'c'], [-24.2, 218.801], [-25.4, 204.401, 'c'], [-25, 176.401, 'c'], [-29.8, 173.601]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-$zinc->add('curve',$top_group,[[7.8, 175.601], [0.6, 194.001, 'c'], [-29, 259.201, 'c'], [-29, 259.201], [-31, 260.801, 'c'], [-16.34, 266.846, 'c'], [-6.2, 264.401], [4.746, 261.763, 'c'], [45, 266.001, 'c'], [45, 266.001], [68.6, 250.401, 'c'], [81.4, 206.001, 'c'], [81.4, 206.001], [81.4, 206.001, 'c'], [91.801, 182.001, 'c'], [74.2, 178.801], [56.6, 175.601, 'c'], [-7.8, 175.601, 'c'], [-7.8, 175.601]], -closed => 1, -fillcolor => "#e5668c", -filled => 1, -linecolor => "#e5668c");
-$zinc->add('curve',$top_group,[[9.831, 206.497], [-6.505, 193.707, 'c'], [-4.921, 181.906, 'c'], [-7.8, 175.601], [-7.8, 175.601, 'c'], [54.6, 182.001, 'c'], [65.8, 161.201], [70.041, 153.326, 'c'], [84.801, 184.001, 'c'], [84.4, 193.601], [84.4, 193.601, 'c'], [21.4, 208.001, 'c'], [6.6, 196.801], [-9.831, 206.497]], -closed => 1, -fillcolor => "#b23259", -filled => 1, -linecolor => "#b23259");
-$zinc->add('curve',$top_group,[[5.4, 222.801], [-5.4, 222.801, 'c'], [-3.4, 230.001, 'c'], [-5.8, 234.001], [-5.8, 234.001, 'c'], [-7.4, 234.801, 'c'], [-8.6, 235.201], [-8.6, 235.201, 'c'], [-7.4, 238.801, 'c'], [-1.4, 240.401], [-1.4, 240.401, 'c'], [0.6, 244.801, 'c'], [3, 245.201], [5.4, 245.601, 'c'], [10.2, 251.201, 'c'], [14.2, 250.001], [18.2, 248.801, 'c'], [29.4, 244.801, 'c'], [29.4, 244.801], [29.4, 244.801, 'c'], [35, 241.601, 'c'], [43.8, 245.201], [43.8, 245.201, 'c'], [46.175, 244.399, 'c'], [46.6, 240.401], [47.1, 235.701, 'c'], [50.2, 232.001, 'c'], [52.2, 230.001], [54.2, 228.001, 'c'], [63.8, 215.201, 'c'], [62.6, 214.801], [61.4, 214.401, 'c'], [-5.4, 222.801, 'c'], [-5.4, 222.801]], -closed => 1, -fillcolor => "#a5264c", -filled => 1, -linecolor => "#a5264c");
-$zinc->add('curve',$top_group,[[9.8, 174.401], [-9.8, 174.401, 'c'], [-12.6, 196.801, 'c'], [-9.4, 205.201], [-6.2, 213.601, 'c'], [-7, 215.601, 'c'], [-7.8, 219.601], [-8.6, 223.601, 'c'], [-4.2, 233.601, 'c'], [1.4, 239.601], [13.4, 241.201], [13.4, 241.201, 'c'], [28.6, 237.601, 'c'], [37.8, 240.401], [37.8, 240.401, 'c'], [46.794, 241.744, 'c'], [50.2, 226.801], [50.2, 226.801, 'c'], [55, 220.401, 'c'], [62.2, 217.601], [69.4, 214.801, 'c'], [76.6, 173.201, 'c'], [72.6, 165.201], [68.6, 157.201, 'c'], [54.2, 152.801, 'c'], [38.2, 168.401], [22.2, 184.001, 'c'], [20.2, 167.201, 'c'], [-9.8, 174.401]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ff727f", -filled => 1);
-$zinc->add('curve',$top_group,[[8.2, 249.201], [-8.2, 249.201, 'c'], [-9, 247.201, 'c'], [-13.4, 246.801], [-13.4, 246.801, 'c'], [-35.8, 243.201, 'c'], [-44.2, 230.801], [-44.2, 230.801, 'c'], [-51, 225.201, 'c'], [-46.6, 236.801], [-46.6, 236.801, 'c'], [-36.2, 257.201, 'c'], [-29.4, 260.001], [-29.4, 260.001, 'c'], [-13, 264.001, 'c'], [-8.2, 249.201]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffcc", -filled => 1, -linewidth => 0.5);
-
-
-$zinc->add('curve',$top_group,[[71.742, 185.229], [72.401, 177.323, 'c'], [74.354, 168.709, 'c'], [72.6, 165.201], [66.154, 152.307, 'c'], [49.181, 157.695, 'c'], [38.2, 168.401], [22.2, 184.001, 'c'], [20.2, 167.201, 'c'], [-9.8, 174.401], [-9.8, 174.401, 'c'], [-11.545, 188.364, 'c'], [-10.705, 198.376], [-10.705, 198.376, 'c'], [26.6, 186.801, 'c'], [27.4, 192.401], [27.4, 192.401, 'c'], [29, 189.201, 'c'], [38.2, 189.201], [47.4, 189.201, 'c'], [70.142, 188.029, 'c'], [71.742, 185.229]], -closed => 1, -fillcolor => "#cc3f4c", -filled => 1, -linecolor => "#cc3f4c");
-$zinc->add('curve',$top_group,[[28.6, 175.201], [28.6, 175.201, 'c'], [33.4, 180.001, 'c'], [29.8, 189.601], [29.8, 189.601, 'c'], [15.4, 205.601, 'c'], [17.4, 219.601]], -closed => 0, -linecolor => "#a51926", -linewidth => 2);
-$zinc->add('curve',$top_group,[[19.4, 260.001], [-19.4, 260.001, 'c'], [-23.8, 247.201, 'c'], [-15, 254.001], [-15, 254.001, 'c'], [-10.2, 256.001, 'c'], [-11.4, 257.601], [-12.6, 259.201, 'c'], [-18.2, 263.201, 'c'], [-19.4, 260.001]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffcc", -filled => 1, -linewidth => 0.5);
-$zinc->add('curve',$top_group,[[14.36, 261.201], [-14.36, 261.201, 'c'], [-17.88, 250.961, 'c'], [-10.84, 256.401], [-10.84, 256.401, 'c'], [-6.419, 258.849, 'c'], [-7.96, 259.281], [-12.52, 260.561, 'c'], [-7.96, 263.121, 'c'], [-14.36, 261.201]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffcc", -filled => 1, -linewidth => 0.5);
-$zinc->add('curve',$top_group,[[9.56, 261.201], [-9.56, 261.201, 'c'], [-13.08, 250.961, 'c'], [-6.04, 256.401], [-6.04, 256.401, 'c'], [-1.665, 258.711, 'c'], [-3.16, 259.281], [-6.52, 260.561, 'c'], [-3.16, 263.121, 'c'], [-9.56, 261.201]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffcc", -filled => 1, -linewidth => 0.5);
-$zinc->add('curve',$top_group,[[2.96, 261.401], [-2.96, 261.401, 'c'], [-6.48, 251.161, 'c'], [0.56, 256.601], [0.56, 256.601, 'c'], [4.943, 258.933, 'c'], [3.441, 259.481], [0.48, 260.561, 'c'], [3.441, 263.321, 'c'], [-2.96, 261.401]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffcc", -filled => 1, -linewidth => 0.5);
-$zinc->add('curve',$top_group,[[3.52, 261.321], [3.52, 261.321, 'c'], [0, 251.081, 'c'], [7.041, 256.521], [7.041, 256.521, 'c'], [10.881, 258.121, 'c'], [9.921, 259.401], [8.961, 260.681, 'c'], [9.921, 263.241, 'c'], [3.52, 261.321]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffcc", -filled => 1, -linewidth => 0.5);
-$zinc->add('curve',$top_group,[[10.2, 262.001], [10.2, 262.001, 'c'], [5.4, 249.601, 'c'], [14.6, 256.001], [14.6, 256.001, 'c'], [19.4, 258.001, 'c'], [18.2, 259.601], [17, 261.201, 'c'], [18.2, 264.401, 'c'], [10.2, 262.001]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffcc", -filled => 1, -linewidth => 0.5);
-$zinc->add('curve',$top_group,[[18.2, 244.801], [-18.2, 244.801, 'c'], [-5, 242.001, 'c'], [1, 245.201], [1, 245.201, 'c'], [7, 246.401, 'c'], [8.2, 246.001], [9.4, 245.601, 'c'], [12.6, 245.201, 'c'], [12.6, 245.201]], -closed => 0, -linecolor => "#a5264c", -linewidth => 2);
-$zinc->add('curve',$top_group,[[15.8, 253.601], [15.8, 253.601, 'c'], [27.8, 240.001, 'c'], [39.8, 244.401], [46.816, 246.974, 'c'], [45.8, 243.601, 'c'], [46.6, 240.801], [47.4, 238.001, 'c'], [47.6, 233.801, 'c'], [52.6, 230.801]], -closed => 0, -linecolor => "#a5264c", -linewidth => 2);
-$zinc->add('curve',$top_group,[[33, 237.601], [33, 237.601, 'c'], [29, 226.801, 'c'], [26.2, 239.601], [23.4, 252.401, 'c'], [20.2, 256.001, 'c'], [18.6, 258.801], [18.6, 258.801, 'c'], [18.6, 264.001, 'c'], [27, 263.601], [27, 263.601, 'c'], [37.8, 263.201, 'c'], [38.2, 260.401], [38.6, 257.601, 'c'], [37, 246.001, 'c'], [33, 237.601]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffcc", -filled => 1, -linewidth => 0.5);
-$zinc->add('curve',$top_group,[[47, 244.801], [47, 244.801, 'c'], [50.6, 242.401, 'c'], [53, 243.601]], -closed => 0, -linecolor => "#a5264c", -linewidth => 2);
-$zinc->add('curve',$top_group,[[53.5, 228.401], [53.5, 228.401, 'c'], [56.4, 223.501, 'c'], [61.2, 222.701]], -closed => 0, -linecolor => "#a5264c", -linewidth => 2);
-$zinc->add('curve',$top_group,[[25.8, 265.201], [-25.8, 265.201, 'c'], [-7.8, 268.401, 'c'], [-3.4, 266.801], [-3.4, 266.801, 'c'], [5.4, 266.801, 'c'], [-3, 268.801], [-3, 268.801, 'c'], [-15.8, 268.801, 'c'], [-23.8, 267.601], [-23.8, 267.601, 'c'], [-35.4, 262.001, 'c'], [-25.8, 265.201]], -closed => 1, -fillcolor => "#b2b2b2", -filled => 1, -linecolor => "#b2b2b2");
-$zinc->add('curve',$top_group,[[11.8, 172.001], [-11.8, 172.001, 'c'], [5.8, 172.001, 'c'], [7.8, 172.801], [7.8, 172.801, 'c'], [15, 203.601, 'c'], [11.4, 211.201], [11.4, 211.201, 'c'], [10.2, 214.001, 'c'], [7.4, 208.401], [7.4, 208.401, 'c'], [-11, 175.601, 'c'], [-14.2, 173.601], [-17.4, 171.601, 'c'], [-13, 172.001, 'c'], [-11.8, 172.001]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffcc", -filled => 1, -linewidth => 0.5);
-
-$zinc->add('curve',$top_group,[[-88.9, 169.301], [-88.9, 169.301, 'c'], [-80, 171.001, 'c'], [-67.4, 173.601], [-67.4, 173.601, 'c'], [-62.6, 196.001, 'c'], [-59.4, 200.801], [-56.2, 205.601, 'c'], [-59.8, 205.601, 'c'], [-63.4, 202.801], [-67, 200.001, 'c'], [-81.8, 186.001, 'c'], [-83.8, 181.601], [-85.8, 177.201, 'c'], [-88.9, 169.301, 'c'], [-88.9, 169.301]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffcc", -filled => 1, -linewidth => 0.5);
-
-$zinc->add('curve',$top_group,[[-67.039, 173.818], [-67.039, 173.818, 'c'], [-61.239, 175.366, 'c'], [-60.23, 177.581], [-59.222, 179.795, 'c'], [-61.432, 183.092, 'c'], [-61.432, 183.092], [-61.432, 183.092, 'c'], [-62.432, 186.397, 'c'], [-63.634, 184.235], [-64.836, 182.072, 'c'], [-67.708, 174.412, 'c'], [-67.039, 173.818]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffcc", -filled => 1, -linewidth => 0.5);
-
-$zinc->add('curve',$top_group,[[-67, 173.601], [-67, 173.601, 'c'], [-63.4, 178.801, 'c'], [-59.8, 178.801], [-56.2, 178.801, 'c'], [-55.818, 178.388, 'c'], [-53, 179.001], [-48.4, 180.001, 'c'], [-48.8, 178.001, 'c'], [-42.2, 179.201], [-39.56, 179.681, 'c'], [-37, 178.801, 'c'], [-34.2, 180.001], [-31.4, 181.201, 'c'], [-28.2, 180.401, 'c'], [-27, 178.401], [-25.8, 176.401, 'c'], [-21, 172.201, 'c'], [-21, 172.201], [-21, 172.201, 'c'], [-33.8, 174.001, 'c'], [-36.6, 174.801], [-36.6, 174.801, 'c'], [-59, 176.001, 'c'], [-67, 173.601]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-22.4, 173.801], [-22.4, 173.801, 'c'], [-28.85, 177.301, 'c'], [-29.25, 179.701], [-29.65, 182.101, 'c'], [-24, 185.801, 'c'], [-24, 185.801], [-24, 185.801, 'c'], [-21.25, 190.401, 'c'], [-20.65, 188.001], [-20.05, 185.601, 'c'], [-21.6, 174.201, 'c'], [-22.4, 173.801]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffcc", -filled => 1, -linewidth => 0.5);
-
-$zinc->add('curve',$top_group,[[-59.885, 179.265], [-59.885, 179.265, 'c'], [-52.878, 190.453, 'c'], [-52.661, 179.242], [-52.661, 179.242, 'c'], [-52.104, 177.984, 'c'], [-53.864, 177.962], [-59.939, 177.886, 'c'], [-58.418, 173.784, 'c'], [-59.885, 179.265]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffcc", -filled => 1, -linewidth => 0.5);
-
-$zinc->add('curve',$top_group,[[-52.707, 179.514], [-52.707, 179.514, 'c'], [-44.786, 190.701, 'c'], [-45.422, 179.421], [-45.422, 179.421, 'c'], [-45.415, 179.089, 'c'], [-47.168, 178.936], [-51.915, 178.522, 'c'], [-51.57, 174.004, 'c'], [-52.707, 179.514]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffcc", -filled => 1, -linewidth => 0.5);
-
-$zinc->add('curve',$top_group,[[-45.494, 179.522], [-45.494, 179.522, 'c'], [-37.534, 190.15, 'c'], [-38.203, 180.484], [-38.203, 180.484, 'c'], [-38.084, 179.251, 'c'], [-39.738, 178.95], [-43.63, 178.244, 'c'], [-43.841, 174.995, 'c'], [-45.494, 179.522]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffcc", -filled => 1, -linewidth => 0.5);
-
-$zinc->add('curve',$top_group,[[-38.618, 179.602], [-38.618, 179.602, 'c'], [-30.718, 191.163, 'c'], [-30.37, 181.382], [-30.37, 181.382, 'c'], [-28.726, 180.004, 'c'], [-30.472, 179.782], [-36.29, 179.042, 'c'], [-35.492, 174.588, 'c'], [-38.618, 179.602]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffcc", -filled => 1, -linewidth => 0.5);
-
-$zinc->add('curve',$top_group,[[-74.792, 183.132], [-82.45, 181.601], [-85.05, 176.601, 'c'], [-87.15, 170.451, 'c'], [-87.15, 170.451], [-87.15, 170.451, 'c'], [-80.8, 171.451, 'c'], [-68.3, 174.251], [-68.3, 174.251, 'c'], [-67.424, 177.569, 'c'], [-65.952, 183.364], [-74.792, 183.132]], -closed => 1, -fillcolor => "#e5e5b2", -filled => 1, -linecolor => "#e5e5b2");
-
-$zinc->add('curve',$top_group,[[-9.724, 178.47], [-11.39, 175.964, 'c'], [-12.707, 174.206, 'c'], [-13.357, 173.8], [-16.37, 171.917, 'c'], [-12.227, 172.294, 'c'], [-11.098, 172.294], [-11.098, 172.294, 'c'], [5.473, 172.294, 'c'], [7.356, 173.047], [7.356, 173.047, 'c'], [7.88, 175.289, 'c'], [8.564, 178.68], [8.564, 178.68, 'c'], [-1.524, 176.67, 'c'], [-9.724, 178.47]], -closed => 1, -fillcolor => "#e5e5b2", -filled => 1, -linecolor => "#e5e5b2");
-
-$zinc->add('curve',$top_group,[[43.88, 40.321], [71.601, 44.281, 'c'], [97.121, 8.641, 'c'], [98.881, -1.04], [100.641, -10.72, 'c'], [90.521, -22.6, 'c'], [90.521, -22.6], [91.841, -25.68, 'c'], [87.001, -39.76, 'c'], [81.721, -49], [76.441, -58.24, 'c'], [60.54, -57.266, 'c'], [43, -58.24], [27.16, -59.12, 'c'], [8.68, -35.8, 'c'], [7.36, -34.04], [6.04, -32.28, 'c'], [12.2, 6.001, 'c'], [13.52, 11.721], [14.84, 17.441, 'c'], [12.2, 43.841, 'c'], [12.2, 43.841], [46.44, 34.741, 'c'], [16.16, 36.361, 'c'], [43.88, 40.321]], -closed => 1, -fillcolor => "#cc7226", -filled => 1, -linecolor => "#cc7226");
-
-$zinc->add('curve',$top_group,[[8.088, -33.392], [6.792, -31.664, 'c'], [12.84, 5.921, 'c'], [14.136, 11.537], [15.432, 17.153, 'c'], [12.84, 43.073, 'c'], [12.84, 43.073], [45.512, 34.193, 'c'], [16.728, 35.729, 'c'], [43.944, 39.617], [71.161, 43.505, 'c'], [96.217, 8.513, 'c'], [97.945, -0.992], [99.673, -10.496, 'c'], [89.737, -22.16, 'c'], [89.737, -22.16], [91.033, -25.184, 'c'], [86.281, -39.008, 'c'], [81.097, -48.08], [75.913, -57.152, 'c'], [60.302, -56.195, 'c'], [43.08, -57.152], [27.528, -58.016, 'c'], [9.384, -35.12, 'c'], [8.088, -33.392]], -closed => 1, -fillcolor => "#ea8e51", -filled => 1, -linecolor => "#ea8e51");
-
-$zinc->add('curve',$top_group,[[8.816, -32.744], [7.544, -31.048, 'c'], [13.48, 5.841, 'c'], [14.752, 11.353], [16.024, 16.865, 'c'], [13.48, 42.305, 'c'], [13.48, 42.305], [44.884, 33.145, 'c'], [17.296, 35.097, 'c'], [44.008, 38.913], [70.721, 42.729, 'c'], [95.313, 8.385, 'c'], [97.009, -0.944], [98.705, -10.272, 'c'], [88.953, -21.72, 'c'], [88.953, -21.72], [90.225, -24.688, 'c'], [85.561, -38.256, 'c'], [80.473, -47.16], [75.385, -56.064, 'c'], [60.063, -55.125, 'c'], [43.16, -56.064], [27.896, -56.912, 'c'], [10.088, -34.44, 'c'], [8.816, -32.744]], -closed => 1, -fillcolor => "#efaa7c", -filled => 1, -linecolor => "#efaa7c");
-
-$zinc->add('curve',$top_group,[[9.544, -32.096], [8.296, -30.432, 'c'], [14.12, 5.761, 'c'], [15.368, 11.169], [16.616, 16.577, 'c'], [14.12, 41.537, 'c'], [14.12, 41.537], [43.556, 32.497, 'c'], [17.864, 34.465, 'c'], [44.072, 38.209], [70.281, 41.953, 'c'], [94.409, 8.257, 'c'], [96.073, -0.895], [97.737, -10.048, 'c'], [88.169, -21.28, 'c'], [88.169, -21.28], [89.417, -24.192, 'c'], [84.841, -37.504, 'c'], [79.849, -46.24], [74.857, -54.976, 'c'], [59.824, -54.055, 'c'], [43.24, -54.976], [28.264, -55.808, 'c'], [10.792, -33.76, 'c'], [9.544, -32.096]], -closed => 1, -fillcolor => "#f4c6a8", -filled => 1, -linecolor => "#f4c6a8");
-
-$zinc->add('curve',$top_group,[[10.272, -31.448], [9.048, -29.816, 'c'], [14.76, 5.681, 'c'], [15.984, 10.985], [17.208, 16.289, 'c'], [14.76, 40.769, 'c'], [14.76, 40.769], [42.628, 31.849, 'c'], [18.432, 33.833, 'c'], [44.136, 37.505], [69.841, 41.177, 'c'], [93.505, 8.129, 'c'], [95.137, -0.848], [96.769, -9.824, 'c'], [87.385, -20.84, 'c'], [87.385, -20.84], [88.609, -23.696, 'c'], [84.121, -36.752, 'c'], [79.225, -45.32], [74.329, -53.888, 'c'], [59.585, -52.985, 'c'], [43.32, -53.888], [28.632, -54.704, 'c'], [11.496, -33.08, 'c'], [10.272, -31.448]], -closed => 1, -fillcolor => "#f9e2d3", -filled => 1, -linecolor => "#f9e2d3");
-
-$zinc->add('curve',$top_group,[[44.2, 36.8], [69.4, 40.4, 'c'], [92.601, 8, 'c'], [94.201, -0.8], [95.801, -9.6, 'c'], [86.601, -20.4, 'c'], [86.601, -20.4], [87.801, -23.2, 'c'], [83.4, -36, 'c'], [78.6, -44.4], [73.8, -52.8, 'c'], [59.346, -51.914, 'c'], [43.4, -52.8], [29, -53.6, 'c'], [12.2, -32.4, 'c'], [11, -30.8], [9.8, -29.2, 'c'], [15.4, 5.6, 'c'], [16.6, 10.8], [17.8, 16, 'c'], [15.4, 40, 'c'], [15.4, 40], [40.9, 31.4, 'c'], [19, 33.2, 'c'], [44.2, 36.8]], -closed => 1, -fillcolor => "#ffffff", -filled => 1, -linecolor => "#ffffff");
-
-$zinc->add('curve',$top_group,[[90.601, 2.8], [90.601, 2.8, 'c'], [62.8, 10.4, 'c'], [51.2, 8.8], [51.2, 8.8, 'c'], [35.4, 2.2, 'c'], [26.6, 24], [26.6, 24, 'c'], [23, 31.2, 'c'], [21, 33.2], [19, 35.2, 'c'], [90.601, 2.8, 'c'], [90.601, 2.8]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[94.401, 0.6], [94.401, 0.6, 'c'], [65.4, 12.8, 'c'], [55.4, 12.4], [55.4, 12.4, 'c'], [39, 7.8, 'c'], [30.6, 22.4], [30.6, 22.4, 'c'], [22.2, 31.6, 'c'], [19, 33.2], [19, 33.2, 'c'], [18.6, 34.8, 'c'], [25, 30.8], [35.4, 36], [35.4, 36, 'c'], [50.2, 45.6, 'c'], [59.8, 29.6], [59.8, 29.6, 'c'], [63.8, 18.4, 'c'], [63.8, 16.4], [63.8, 14.4, 'c'], [85, 8.8, 'c'], [86.601, 8.4], [88.201, 8, 'c'], [94.801, 3.8, 'c'], [94.401, 0.6]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[47, 36.514], [40.128, 36.514, 'c'], [31.755, 32.649, 'c'], [31.755, 26.4], [31.755, 20.152, 'c'], [40.128, 13.887, 'c'], [47, 13.887], [53.874, 13.887, 'c'], [59.446, 18.952, 'c'], [59.446, 25.2], [59.446, 31.449, 'c'], [53.874, 36.514, 'c'], [47, 36.514]], -closed => 1, -fillcolor => "#99cc32", -filled => 1, -linecolor => "#99cc32");
-
-$zinc->add('curve',$top_group,[[43.377, 19.83], [38.531, 20.552, 'c'], [33.442, 22.055, 'c'], [33.514, 21.839], [35.054, 17.22, 'c'], [41.415, 13.887, 'c'], [47, 13.887], [51.296, 13.887, 'c'], [55.084, 15.865, 'c'], [57.32, 18.875], [57.32, 18.875, 'c'], [52.004, 18.545, 'c'], [43.377, 19.83]], -closed => 1, -fillcolor => "#659900", -filled => 1, -linecolor => "#659900");
-
-$zinc->add('curve',$top_group,[[55.4, 19.6], [55.4, 19.6, 'c'], [51, 16.4, 'c'], [51, 18.6], [51, 18.6, 'c'], [54.6, 23, 'c'], [55.4, 19.6]], -closed => 1, -fillcolor => "#ffffff", -filled => 1, -linecolor => "#ffffff");
-
-$zinc->add('curve',$top_group,[[45.4, 27.726], [42.901, 27.726, 'c'], [40.875, 25.7, 'c'], [40.875, 23.2], [40.875, 20.701, 'c'], [42.901, 18.675, 'c'], [45.4, 18.675], [47.9, 18.675, 'c'], [49.926, 20.701, 'c'], [49.926, 23.2], [49.926, 25.7, 'c'], [47.9, 27.726, 'c'], [45.4, 27.726]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-58.6, 14.4], [-58.6, 14.4, 'c'], [-61.8, -6.8, 'c'], [-59.4, -11.2], [-59.4, -11.2, 'c'], [-48.6, -21.2, 'c'], [-49, -24.8], [-49, -24.8, 'c'], [-49.4, -42.8, 'c'], [-50.6, -43.6], [-51.8, -44.4, 'c'], [-59.4, -50.4, 'c'], [-65.4, -44], [-65.4, -44, 'c'], [-75.8, -26, 'c'], [-75, -19.6], [-75, -17.6], [-75, -17.6, 'c'], [-82.6, -18, 'c'], [-84.2, -16], [-84.2, -16, 'c'], [-85.4, -10.8, 'c'], [-86.6, -10.4], [-86.6, -10.4, 'c'], [-89.4, -8, 'c'], [-87.4, -5.2], [-87.4, -5.2, 'c'], [-89.4, -2.8, 'c'], [-89, 1.2], [-81.4, 5.2], [-81.4, 5.2, 'c'], [-79.4, 19.6, 'c'], [-68.6, 24.8], [-63.764, 27.129, 'c'], [-60.6, 20.4, 'c'], [-58.6, 14.4]], -closed => 1, -fillcolor => "#cc7226", -filled => 1, -linecolor => "#cc7226");
-
-$zinc->add('curve',$top_group,[[-59.6, 12.56], [-59.6, 12.56, 'c'], [-62.48, -6.52, 'c'], [-60.32, -10.48], [-60.32, -10.48, 'c'], [-50.6, -19.48, 'c'], [-50.96, -22.72], [-50.96, -22.72, 'c'], [-51.32, -38.92, 'c'], [-52.4, -39.64], [-53.48, -40.36, 'c'], [-60.32, -45.76, 'c'], [-65.72, -40], [-65.72, -40, 'c'], [-75.08, -23.8, 'c'], [-74.36, -18.04], [-74.36, -16.24], [-74.36, -16.24, 'c'], [-81.2, -16.6, 'c'], [-82.64, -14.8], [-82.64, -14.8, 'c'], [-83.72, -10.12, 'c'], [-84.8, -9.76], [-84.8, -9.76, 'c'], [-87.32, -7.6, 'c'], [-85.52, -5.08], [-85.52, -5.08, 'c'], [-87.32, -2.92, 'c'], [-86.96, 0.68], [-80.12, 4.28], [-80.12, 4.28, 'c'], [-78.32, 17.24, 'c'], [-68.6, 21.92], [-64.248, 24.015, 'c'], [-61.4, 17.96, 'c'], [-59.6, 12.56]], -closed => 1, -fillcolor => "#ffffff", -filled => 1, -linecolor => "#ffffff");
-
-$zinc->add('curve',$top_group,[[-51.05, -42.61], [-52.14, -43.47, 'c'], [-59.63, -49.24, 'c'], [-65.48, -43], [-65.48, -43, 'c'], [-75.62, -25.45, 'c'], [-74.84, -19.21], [-74.84, -17.26], [-74.84, -17.26, 'c'], [-82.25, -17.65, 'c'], [-83.81, -15.7], [-83.81, -15.7, 'c'], [-84.98, -10.63, 'c'], [-86.15, -10.24], [-86.15, -10.24, 'c'], [-88.88, -7.9, 'c'], [-86.93, -5.17], [-86.93, -5.17, 'c'], [-88.88, -2.83, 'c'], [-88.49, 1.07], [-81.08, 4.97], [-81.08, 4.97, 'c'], [-79.13, 19.01, 'c'], [-68.6, 24.08], [-63.886, 26.35, 'c'], [-60.8, 19.79, 'c'], [-58.85, 13.94], [-58.85, 13.94, 'c'], [-61.97, -6.73, 'c'], [-59.63, -11.02], [-59.63, -11.02, 'c'], [-49.1, -20.77, 'c'], [-49.49, -24.28], [-49.49, -24.28, 'c'], [-49.88, -41.83, 'c'], [-51.05, -42.61]], -closed => 1, -fillcolor => "#eb955c", -filled => 1, -linecolor => "#eb955c");
-
-$zinc->add('curve',$top_group,[[-51.5, -41.62], [-52.48, -42.54, 'c'], [-59.86, -48.08, 'c'], [-65.56, -42], [-65.56, -42, 'c'], [-75.44, -24.9, 'c'], [-74.68, -18.82], [-74.68, -16.92], [-74.68, -16.92, 'c'], [-81.9, -17.3, 'c'], [-83.42, -15.4], [-83.42, -15.4, 'c'], [-84.56, -10.46, 'c'], [-85.7, -10.08], [-85.7, -10.08, 'c'], [-88.36, -7.8, 'c'], [-86.46, -5.14], [-86.46, -5.14, 'c'], [-88.36, -2.86, 'c'], [-87.98, 0.94], [-80.76, 4.74], [-80.76, 4.74, 'c'], [-78.86, 18.42, 'c'], [-68.6, 23.36], [-64.006, 25.572, 'c'], [-61, 19.18, 'c'], [-59.1, 13.48], [-59.1, 13.48, 'c'], [-62.14, -6.66, 'c'], [-59.86, -10.84], [-59.86, -10.84, 'c'], [-49.6, -20.34, 'c'], [-49.98, -23.76], [-49.98, -23.76, 'c'], [-50.36, -40.86, 'c'], [-51.5, -41.62]], -closed => 1, -fillcolor => "#f2b892", -filled => 1, -linecolor => "#f2b892");
-
-$zinc->add('curve',$top_group,[[-51.95, -40.63], [-52.82, -41.61, 'c'], [-60.09, -46.92, 'c'], [-65.64, -41], [-65.64, -41, 'c'], [-75.26, -24.35, 'c'], [-74.52, -18.43], [-74.52, -16.58], [-74.52, -16.58, 'c'], [-81.55, -16.95, 'c'], [-83.03, -15.1], [-83.03, -15.1, 'c'], [-84.14, -10.29, 'c'], [-85.25, -9.92], [-85.25, -9.92, 'c'], [-87.84, -7.7, 'c'], [-85.99, -5.11], [-85.99, -5.11, 'c'], [-87.84, -2.89, 'c'], [-87.47, 0.81], [-80.44, 4.51], [-80.44, 4.51, 'c'], [-78.59, 17.83, 'c'], [-68.6, 22.64], [-64.127, 24.794, 'c'], [-61.2, 18.57, 'c'], [-59.35, 13.02], [-59.35, 13.02, 'c'], [-62.31, -6.59, 'c'], [-60.09, -10.66], [-60.09, -10.66, 'c'], [-50.1, -19.91, 'c'], [-50.47, -23.24], [-50.47, -23.24, 'c'], [-50.84, -39.89, 'c'], [-51.95, -40.63]], -closed => 1, -fillcolor => "#f8dcc8", -filled => 1, -linecolor => "#f8dcc8");
-
-$zinc->add('curve',$top_group,[[-59.6, 12.46], [-59.6, 12.46, 'c'], [-62.48, -6.52, 'c'], [-60.32, -10.48], [-60.32, -10.48, 'c'], [-50.6, -19.48, 'c'], [-50.96, -22.72], [-50.96, -22.72, 'c'], [-51.32, -38.92, 'c'], [-52.4, -39.64], [-53.16, -40.68, 'c'], [-60.32, -45.76, 'c'], [-65.72, -40], [-65.72, -40, 'c'], [-75.08, -23.8, 'c'], [-74.36, -18.04], [-74.36, -16.24], [-74.36, -16.24, 'c'], [-81.2, -16.6, 'c'], [-82.64, -14.8], [-82.64, -14.8, 'c'], [-83.72, -10.12, 'c'], [-84.8, -9.76], [-84.8, -9.76, 'c'], [-87.32, -7.6, 'c'], [-85.52, -5.08], [-85.52, -5.08, 'c'], [-87.32, -2.92, 'c'], [-86.96, 0.68], [-80.12, 4.28], [-80.12, 4.28, 'c'], [-78.32, 17.24, 'c'], [-68.6, 21.92], [-64.248, 24.015, 'c'], [-61.4, 17.86, 'c'], [-59.6, 12.46]], -closed => 1, -fillcolor => "#ffffff", -filled => 1, -linecolor => "#ffffff");
-
-$zinc->add('curve',$top_group,[[-62.7, 6.2], [-62.7, 6.2, 'c'], [-84.3, -4, 'c'], [-85.2, -4.8], [-85.2, -4.8, 'c'], [-76.1, 3.4, 'c'], [-75.3, 3.4], [-74.5, 3.4, 'c'], [-62.7, 6.2, 'c'], [-62.7, 6.2]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[-79.8, 0], [-79.8, 0, 'c'], [-61.4, 3.6, 'c'], [-61.4, 8], [-61.4, 10.912, 'c'], [-61.643, 24.331, 'c'], [-67, 22.8], [-75.4, 20.4, 'c'], [-71.8, 6, 'c'], [-79.8, 0]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-71.4, 3.8], [-71.4, 3.8, 'c'], [-62.422, 5.274, 'c'], [-61.4, 8], [-60.8, 9.6, 'c'], [-60.137, 17.908, 'c'], [-65.6, 19], [-70.152, 19.911, 'c'], [-72.382, 9.69, 'c'], [-71.4, 3.8]], -closed => 1, -fillcolor => "#99cc32", -filled => 1, -linecolor => "#99cc32");
-
-$zinc->add('curve',$top_group,[[14.595, 46.349], [14.098, 44.607, 'c'], [15.409, 44.738, 'c'], [17.2, 44.2], [19.2, 43.6, 'c'], [31.4, 39.8, 'c'], [32.2, 37.2], [33, 34.6, 'c'], [46.2, 39, 'c'], [46.2, 39], [48, 39.8, 'c'], [52.4, 42.4, 'c'], [52.4, 42.4], [57.2, 43.6, 'c'], [63.8, 44, 'c'], [63.8, 44], [66.2, 45, 'c'], [69.6, 47.8, 'c'], [69.6, 47.8], [84.2, 58, 'c'], [96.601, 50.8, 'c'], [96.601, 50.8], [116.601, 44.2, 'c'], [110.601, 27, 'c'], [110.601, 27], [107.601, 18, 'c'], [110.801, 14.6, 'c'], [110.801, 14.6], [111.001, 10.8, 'c'], [118.201, 17.2, 'c'], [118.201, 17.2], [120.801, 21.4, 'c'], [121.601, 26.4, 'c'], [121.601, 26.4], [129.601, 37.6, 'c'], [126.201, 19.8, 'c'], [126.201, 19.8], [126.401, 18.8, 'c'], [123.601, 15.2, 'c'], [123.601, 14], [123.601, 12.8, 'c'], [121.801, 9.4, 'c'], [121.801, 9.4], [118.801, 6, 'c'], [121.201, -1, 'c'], [121.201, -1], [123.001, -14.8, 'c'], [120.801, -13, 'c'], [120.801, -13], [119.601, -14.8, 'c'], [110.401, -4.8, 'c'], [110.401, -4.8], [108.201, -1.4, 'c'], [102.201, 0.2, 'c'], [102.201, 0.2], [99.401, 2, 'c'], [96.001, 0.6, 'c'], [96.001, 0.6], [93.401, 0.2, 'c'], [87.801, 7.2, 'c'], [87.801, 7.2], [90.601, 7, 'c'], [93.001, 11.4, 'c'], [95.401, 11.6], [97.801, 11.8, 'c'], [99.601, 9.2, 'c'], [101.201, 8.6], [102.801, 8, 'c'], [105.601, 13.8, 'c'], [105.601, 13.8], [106.001, 16.4, 'c'], [100.401, 21.2, 'c'], [100.401, 21.2], [100.001, 25.8, 'c'], [98.401, 24.2, 'c'], [98.401, 24.2], [95.401, 23.6, 'c'], [94.201, 27.4, 'c'], [93.201, 32], [92.201, 36.6, 'c'], [88.001, 37, 'c'], [88.001, 37], [86.401, 44.4, 'c'], [85.2, 41.4, 'c'], [85.2, 41.4], [85, 35.8, 'c'], [79, 41.6, 'c'], [79, 41.6], [77.8, 43.6, 'c'], [73.2, 41.4, 'c'], [73.2, 41.4], [66.4, 39.4, 'c'], [68.8, 37.4, 'c'], [68.8, 37.4], [70.6, 35.2, 'c'], [81.8, 37.4, 'c'], [81.8, 37.4], [84, 35.8, 'c'], [76, 31.8, 'c'], [76, 31.8], [75.4, 30, 'c'], [76.4, 25.6, 'c'], [76.4, 25.6], [77.6, 22.4, 'c'], [84.4, 16.8, 'c'], [84.4, 16.8], [93.801, 15.6, 'c'], [91.001, 14, 'c'], [91.001, 14], [84.801, 8.8, 'c'], [79, 16.4, 'c'], [79, 16.4], [76.8, 22.6, 'c'], [59.4, 37.6, 'c'], [59.4, 37.6], [54.6, 41, 'c'], [57.2, 34.2, 'c'], [53.2, 37.6], [49.2, 41, 'c'], [28.6, 32, 'c'], [28.6, 32], [17.038, 30.807, 'c'], [14.306, 46.549, 'c'], [10.777, 43.429], [10.777, 43.429, 'c'], [16.195, 51.949, 'c'], [14.595, 46.349]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[209.401, -120], [209.401, -120, 'c'], [183.801, -112, 'c'], [181.001, -93.2], [181.001, -93.2, 'c'], [178.601, -70.4, 'c'], [199.001, -52.8], [199.001, -52.8, 'c'], [199.401, -46.4, 'c'], [201.401, -43.2], [201.401, -43.2, 'c'], [199.801, -38.4, 'c'], [218.601, -46], [245.801, -54.4], [245.801, -54.4, 'c'], [252.201, -56.8, 'c'], [257.401, -65.6], [262.601, -74.4, 'c'], [277.801, -93.2, 'c'], [274.201, -118.4], [274.201, -118.4, 'c'], [275.401, -129.6, 'c'], [269.401, -130], [269.401, -130, 'c'], [261.001, -131.6, 'c'], [253.801, -124], [253.801, -124, 'c'], [247.001, -120.8, 'c'], [244.601, -121.2], [209.401, -120]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[264.022, -120.99], [264.022, -120.99, 'c'], [266.122, -129.92, 'c'], [261.282, -125.08], [261.282, -125.08, 'c'], [254.242, -119.36, 'c'], [246.761, -119.36], [246.761, -119.36, 'c'], [232.241, -117.16, 'c'], [227.841, -103.96], [227.841, -103.96, 'c'], [223.881, -77.12, 'c'], [231.801, -71.4], [231.801, -71.4, 'c'], [236.641, -63.92, 'c'], [243.681, -70.52], [250.722, -77.12, 'c'], [266.222, -107.35, 'c'], [264.022, -120.99]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[263.648, -120.632], [263.648, -120.632, 'c'], [265.738, -129.376, 'c'], [260.986, -124.624], [260.986, -124.624, 'c'], [254.074, -119.008, 'c'], [246.729, -119.008], [246.729, -119.008, 'c'], [232.473, -116.848, 'c'], [228.153, -103.888], [228.153, -103.888, 'c'], [224.265, -77.536, 'c'], [232.041, -71.92], [232.041, -71.92, 'c'], [236.793, -64.576, 'c'], [243.705, -71.056], [250.618, -77.536, 'c'], [265.808, -107.24, 'c'], [263.648, -120.632]], -closed => 1, -fillcolor => "#323232", -filled => 1, -linecolor => "#323232");
-
-$zinc->add('curve',$top_group,[[263.274, -120.274], [263.274, -120.274, 'c'], [265.354, -128.832, 'c'], [260.69, -124.168], [260.69, -124.168, 'c'], [253.906, -118.656, 'c'], [246.697, -118.656], [246.697, -118.656, 'c'], [232.705, -116.536, 'c'], [228.465, -103.816], [228.465, -103.816, 'c'], [224.649, -77.952, 'c'], [232.281, -72.44], [232.281, -72.44, 'c'], [236.945, -65.232, 'c'], [243.729, -71.592], [250.514, -77.952, 'c'], [265.394, -107.13, 'c'], [263.274, -120.274]], -closed => 1, -fillcolor => "#666666", -filled => 1, -linecolor => "#666666");
-
-$zinc->add('curve',$top_group,[[262.9, -119.916], [262.9, -119.916, 'c'], [264.97, -128.288, 'c'], [260.394, -123.712], [260.394, -123.712, 'c'], [253.738, -118.304, 'c'], [246.665, -118.304], [246.665, -118.304, 'c'], [232.937, -116.224, 'c'], [228.777, -103.744], [228.777, -103.744, 'c'], [225.033, -78.368, 'c'], [232.521, -72.96], [232.521, -72.96, 'c'], [237.097, -65.888, 'c'], [243.753, -72.128], [250.41, -78.368, 'c'], [264.98, -107.02, 'c'], [262.9, -119.916]], -closed => 1, -fillcolor => "#999999", -filled => 1, -linecolor => "#999999");
-
-$zinc->add('curve',$top_group,[[262.526, -119.558], [262.526, -119.558, 'c'], [264.586, -127.744, 'c'], [260.098, -123.256], [260.098, -123.256, 'c'], [253.569, -117.952, 'c'], [246.633, -117.952], [246.633, -117.952, 'c'], [233.169, -115.912, 'c'], [229.089, -103.672], [229.089, -103.672, 'c'], [225.417, -78.784, 'c'], [232.761, -73.48], [232.761, -73.48, 'c'], [237.249, -66.544, 'c'], [243.777, -72.664], [250.305, -78.784, 'c'], [264.566, -106.91, 'c'], [262.526, -119.558]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[262.151, -119.2], [262.151, -119.2, 'c'], [264.201, -127.2, 'c'], [259.801, -122.8], [259.801, -122.8, 'c'], [253.401, -117.6, 'c'], [246.601, -117.6], [246.601, -117.6, 'c'], [233.401, -115.6, 'c'], [229.401, -103.6], [229.401, -103.6, 'c'], [225.801, -79.2, 'c'], [233.001, -74], [233.001, -74, 'c'], [237.401, -67.2, 'c'], [243.801, -73.2], [250.201, -79.2, 'c'], [264.151, -106.8, 'c'], [262.151, -119.2]], -closed => 1, -fillcolor => "#ffffff", -filled => 1, -linecolor => "#ffffff");
-
-$zinc->add('curve',$top_group,[[50.6, 84], [50.6, 84, 'c'], [30.2, 64.8, 'c'], [22.2, 64], [22.2, 64, 'c'], [-12.2, 60, 'c'], [-27, 78], [-27, 78, 'c'], [-9.4, 57.6, 'c'], [18.2, 63.2], [18.2, 63.2, 'c'], [-3.4, 58.8, 'c'], [-15.8, 62], [-15.8, 62, 'c'], [-32.6, 62, 'c'], [-42.2, 76], [-45, 80.8], [-45, 80.8, 'c'], [-41, 66, 'c'], [-22.6, 60], [-22.6, 60, 'c'], [0.2, 55.2, 'c'], [11, 60], [11, 60, 'c'], [-10.6, 53.2, 'c'], [-20.6, 55.2], [-20.6, 55.2, 'c'], [-51, 52.8, 'c'], [-63.8, 79.2], [-63.8, 79.2, 'c'], [-59.8, 64.8, 'c'], [-45, 57.6], [-45, 57.6, 'c'], [-31.4, 48.8, 'c'], [-11, 51.6], [-11, 51.6, 'c'], [3.4, 54.8, 'c'], [8.6, 57.2], [13.8, 59.6, 'c'], [12.6, 56.8, 'c'], [4.2, 52], [4.2, 52, 'c'], [-1.4, 42, 'c'], [-15.4, 42.4], [-15.4, 42.4, 'c'], [-58.2, 46, 'c'], [-68.6, 58], [-68.6, 58, 'c'], [-55, 46.8, 'c'], [-44.6, 44], [-44.6, 44, 'c'], [-22.2, 36, 'c'], [-13.8, 36.8], [-13.8, 36.8, 'c'], [11, 37.8, 'c'], [18.6, 33.8], [18.6, 33.8, 'c'], [7.4, 38.8, 'c'], [10.6, 42], [13.8, 45.2, 'c'], [20.6, 52.8, 'c'], [20.6, 54], [20.6, 55.2, 'c'], [44.8, 77.3, 'c'], [48.4, 81.7], [50.6, 84]], -closed => 1, -fillcolor => "#992600", -filled => 1, -linecolor => "#992600");
-
-$zinc->add('curve',$top_group,[[189, 278], [189, 278, 'c'], [173.5, 241.5, 'c'], [161, 232], [161, 232, 'c'], [187, 248, 'c'], [190.5, 266], [190.5, 266, 'c'], [190.5, 276, 'c'], [189, 278]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[236, 285.5], [236, 285.5, 'c'], [209.5, 230.5, 'c'], [191, 206.5], [191, 206.5, 'c'], [234.5, 244, 'c'], [239.5, 270.5], [240, 276], [237, 273.5], [237, 273.5, 'c'], [236.5, 282.5, 'c'], [236, 285.5]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[292.5, 237], [292.5, 237, 'c'], [230, 177.5, 'c'], [228.5, 175], [228.5, 175, 'c'], [289, 241, 'c'], [292, 248.5], [292, 248.5, 'c'], [290, 239.5, 'c'], [292.5, 237]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[104, 280.5], [104, 280.5, 'c'], [123.5, 228.5, 'c'], [142.5, 251], [142.5, 251, 'c'], [157.5, 261, 'c'], [157, 264], [157, 264, 'c'], [153, 257.5, 'c'], [135, 258], [135, 258, 'c'], [116, 255, 'c'], [104, 280.5]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[294.5, 153], [294.5, 153, 'c'], [249.5, 124.5, 'c'], [242, 123], [230.193, 120.639, 'c'], [291.5, 152, 'c'], [296.5, 162.5], [296.5, 162.5, 'c'], [298.5, 160, 'c'], [294.5, 153]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[143.801, 259.601], [143.801, 259.601, 'c'], [164.201, 257.601, 'c'], [171.001, 250.801], [175.401, 254.401], [193.001, 216.001], [196.601, 221.201], [196.601, 221.201, 'c'], [211.001, 206.401, 'c'], [210.201, 198.401], [209.401, 190.401, 'c'], [223.001, 204.401, 'c'], [223.001, 204.401], [223.001, 204.401, 'c'], [222.201, 192.801, 'c'], [229.401, 199.601], [229.401, 199.601, 'c'], [227.001, 184.001, 'c'], [235.401, 192.001], [235.401, 192.001, 'c'], [224.864, 161.844, 'c'], [247.401, 187.601], [253.001, 194.001, 'c'], [248.601, 187.201, 'c'], [248.601, 187.201], [248.601, 187.201, 'c'], [222.601, 139.201, 'c'], [244.201, 153.601], [244.201, 153.601, 'c'], [246.201, 130.801, 'c'], [245.001, 126.401], [243.801, 122.001, 'c'], [241.801, 99.6, 'c'], [237.001, 94.4], [232.201, 89.2, 'c'], [237.401, 87.6, 'c'], [243.001, 92.8], [243.001, 92.8, 'c'], [231.801, 68.8, 'c'], [245.001, 80.8], [245.001, 80.8, 'c'], [241.401, 65.6, 'c'], [237.001, 62.8], [237.001, 62.8, 'c'], [231.401, 45.6, 'c'], [246.601, 56.4], [246.601, 56.4, 'c'], [242.201, 44, 'c'], [239.001, 40.8], [239.001, 40.8, 'c'], [227.401, 13.2, 'c'], [234.601, 18], [239.001, 21.6], [239.001, 21.6, 'c'], [232.201, 7.6, 'c'], [238.601, 12], [245.001, 16.4, 'c'], [245.001, 16, 'c'], [245.001, 16], [245.001, 16, 'c'], [223.801, -17.2, 'c'], [244.201, 0.4], [244.201, 0.4, 'c'], [236.042, -13.518, 'c'], [232.601, -20.4], [232.601, -20.4, 'c'], [213.801, -40.8, 'c'], [228.201, -34.4], [233.001, -32.8], [233.001, -32.8, 'c'], [224.201, -42.8, 'c'], [216.201, -44.4], [208.201, -46, 'c'], [218.601, -52.4, 'c'], [225.001, -50.4], [231.401, -48.4, 'c'], [247.001, -40.8, 'c'], [247.001, -40.8], [247.001, -40.8, 'c'], [259.801, -22, 'c'], [263.801, -21.6], [263.801, -21.6, 'c'], [243.801, -29.2, 'c'], [249.801, -21.2], [249.801, -21.2, 'c'], [264.201, -7.2, 'c'], [257.001, -7.6], [257.001, -7.6, 'c'], [251.001, -0.4, 'c'], [255.801, 8.4], [255.801, 8.4, 'c'], [237.342, -9.991, 'c'], [252.201, 15.6], [259.001, 32], [259.001, 32, 'c'], [234.601, 7.2, 'c'], [245.801, 29.2], [245.801, 29.2, 'c'], [263.001, 52.8, 'c'], [265.001, 53.2], [267.001, 53.6, 'c'], [271.401, 62.4, 'c'], [271.401, 62.4], [267.001, 60.4], [272.201, 69.2], [272.201, 69.2, 'c'], [261.001, 57.2, 'c'], [267.001, 70.4], [272.601, 84.8], [272.601, 84.8, 'c'], [252.201, 62.8, 'c'], [265.801, 92.4], [265.801, 92.4, 'c'], [249.401, 87.2, 'c'], [258.201, 104.4], [258.201, 104.4, 'c'], [256.601, 120.401, 'c'], [257.001, 125.601], [257.401, 130.801, 'c'], [258.601, 159.201, 'c'], [254.201, 167.201], [249.801, 175.201, 'c'], [260.201, 194.401, 'c'], [262.201, 198.401], [264.201, 202.401, 'c'], [267.801, 213.201, 'c'], [259.001, 204.001], [250.201, 194.801, 'c'], [254.601, 200.401, 'c'], [256.601, 209.201], [258.601, 218.001, 'c'], [264.601, 233.601, 'c'], [263.801, 239.201], [263.801, 239.201, 'c'], [262.601, 240.401, 'c'], [259.401, 236.801], [259.401, 236.801, 'c'], [244.601, 214.001, 'c'], [246.201, 228.401], [246.201, 228.401, 'c'], [245.001, 236.401, 'c'], [241.801, 245.201], [241.801, 245.201, 'c'], [238.601, 256.001, 'c'], [238.601, 247.201], [238.601, 247.201, 'c'], [235.401, 230.401, 'c'], [232.601, 238.001], [229.801, 245.601, 'c'], [226.201, 251.601, 'c'], [223.401, 254.001], [220.601, 256.401, 'c'], [215.401, 233.601, 'c'], [214.201, 244.001], [214.201, 244.001, 'c'], [202.201, 231.601, 'c'], [197.401, 248.001], [185.801, 264.401], [185.801, 264.401, 'c'], [185.401, 252.001, 'c'], [184.201, 258.001], [184.201, 258.001, 'c'], [154.201, 264.001, 'c'], [143.801, 259.601]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[109.401, -97.2], [109.401, -97.2, 'c'], [97.801, -105.2, 'c'], [93.801, -104.8], [89.801, -104.4, 'c'], [121.401, -113.6, 'c'], [162.601, -86], [162.601, -86, 'c'], [167.401, -83.2, 'c'], [171.001, -83.6], [171.001, -83.6, 'c'], [174.201, -81.2, 'c'], [171.401, -77.6], [171.401, -77.6, 'c'], [162.601, -68, 'c'], [173.801, -56.8], [173.801, -56.8, 'c'], [192.201, -50, 'c'], [186.601, -58.8], [186.601, -58.8, 'c'], [197.401, -54.8, 'c'], [199.801, -50.8], [202.201, -46.8, 'c'], [201.001, -50.8, 'c'], [201.001, -50.8], [201.001, -50.8, 'c'], [194.601, -58, 'c'], [188.601, -63.2], [188.601, -63.2, 'c'], [183.401, -65.2, 'c'], [180.601, -73.6], [177.801, -82, 'c'], [175.401, -92, 'c'], [179.801, -95.2], [179.801, -95.2, 'c'], [175.801, -90.8, 'c'], [176.601, -94.8], [177.401, -98.8, 'c'], [181.001, -102.4, 'c'], [182.601, -102.8], [184.201, -103.2, 'c'], [200.601, -119, 'c'], [207.401, -119.4], [207.401, -119.4, 'c'], [198.201, -118, 'c'], [195.201, -119], [192.201, -120, 'c'], [165.601, -131.4, 'c'], [159.601, -132.6], [159.601, -132.6, 'c'], [142.801, -139.2, 'c'], [154.801, -137.2], [154.801, -137.2, 'c'], [190.601, -133.4, 'c'], [208.801, -120.2], [208.801, -120.2, 'c'], [201.601, -128.6, 'c'], [183.201, -135.6], [183.201, -135.6, 'c'], [161.001, -148.2, 'c'], [125.801, -143.2], [125.801, -143.2, 'c'], [108.001, -140, 'c'], [100.201, -138.2], [100.201, -138.2, 'c'], [97.601, -138.8, 'c'], [97.001, -139.2], [96.401, -139.6, 'c'], [84.6, -148.6, 'c'], [57, -141.6], [57, -141.6, 'c'], [40, -137, 'c'], [31.4, -132.2], [31.4, -132.2, 'c'], [16.2, -131, 'c'], [12.6, -127.8], [12.6, -127.8, 'c'], [-6, -113.2, 'c'], [-8, -112.4], [-10, -111.6, 'c'], [-21.4, -104, 'c'], [-22.2, -103.6], [-22.2, -103.6, 'c'], [2.4, -110.2, 'c'], [4.8, -112.6], [7.2, -115, 'c'], [24.6, -117.6, 'c'], [27, -116.2], [29.4, -114.8, 'c'], [37.8, -115.4, 'c'], [28.2, -114.8], [28.2, -114.8, 'c'], [103.801, -100, 'c'], [104.601, -98], [105.401, -96, 'c'], [109.401, -97.2, 'c'], [109.401, -97.2]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[180.801, -106.4], [180.801, -106.4, 'c'], [170.601, -113.8, 'c'], [168.601, -113.8], [166.601, -113.8, 'c'], [154.201, -124, 'c'], [150.001, -123.6], [145.801, -123.2, 'c'], [133.601, -133.2, 'c'], [106.201, -125], [106.201, -125, 'c'], [105.601, -127, 'c'], [109.201, -127.8], [109.201, -127.8, 'c'], [115.601, -130, 'c'], [116.001, -130.6], [116.001, -130.6, 'c'], [136.201, -134.8, 'c'], [143.401, -131.2], [143.401, -131.2, 'c'], [152.601, -128.6, 'c'], [158.801, -122.4], [158.801, -122.4, 'c'], [170.001, -119.2, 'c'], [173.201, -120.2], [173.201, -120.2, 'c'], [182.001, -118, 'c'], [182.401, -116.2], [182.401, -116.2, 'c'], [188.201, -113.2, 'c'], [186.401, -110.6], [186.401, -110.6, 'c'], [186.801, -109, 'c'], [180.801, -106.4]], -closed => 1, -fillcolor => "#cc7226", -filled => 1, -linecolor => "#cc7226");
-
-$zinc->add('curve',$top_group,[[168.33, -108.509], [169.137, -107.877, 'c'], [170.156, -107.779, 'c'], [170.761, -106.97], [170.995, -106.656, 'c'], [170.706, -106.33, 'c'], [170.391, -106.233], [169.348, -105.916, 'c'], [168.292, -106.486, 'c'], [167.15, -105.898], [166.748, -105.691, 'c'], [166.106, -105.873, 'c'], [165.553, -106.022], [163.921, -106.463, 'c'], [162.092, -106.488, 'c'], [160.401, -105.8], [158.416, -106.929, 'c'], [156.056, -106.345, 'c'], [153.975, -107.346], [153.917, -107.373, 'c'], [153.695, -107.027, 'c'], [153.621, -107.054], [150.575, -108.199, 'c'], [146.832, -107.916, 'c'], [144.401, -110.2], [141.973, -110.612, 'c'], [139.616, -111.074, 'c'], [137.188, -111.754], [135.37, -112.263, 'c'], [133.961, -113.252, 'c'], [132.341, -114.084], [130.964, -114.792, 'c'], [129.507, -115.314, 'c'], [127.973, -115.686], [126.11, -116.138, 'c'], [124.279, -116.026, 'c'], [122.386, -116.546], [122.293, -116.571, 'c'], [122.101, -116.227, 'c'], [122.019, -116.254], [121.695, -116.362, 'c'], [121.405, -116.945, 'c'], [121.234, -116.892], [119.553, -116.37, 'c'], [118.065, -117.342, 'c'], [116.401, -117], [115.223, -118.224, 'c'], [113.495, -117.979, 'c'], [111.949, -118.421], [108.985, -119.269, 'c'], [105.831, -117.999, 'c'], [102.801, -119], [106.914, -120.842, 'c'], [111.601, -119.61, 'c'], [115.663, -121.679], [117.991, -122.865, 'c'], [120.653, -121.763, 'c'], [123.223, -122.523], [123.71, -122.667, 'c'], [124.401, -122.869, 'c'], [124.801, -122.2], [124.935, -122.335, 'c'], [125.117, -122.574, 'c'], [125.175, -122.546], [127.625, -121.389, 'c'], [129.94, -120.115, 'c'], [132.422, -119.049], [132.763, -118.903, 'c'], [133.295, -119.135, 'c'], [133.547, -118.933], [135.067, -117.717, 'c'], [137.01, -117.82, 'c'], [138.401, -116.6], [140.099, -117.102, 'c'], [141.892, -116.722, 'c'], [143.621, -117.346], [143.698, -117.373, 'c'], [143.932, -117.032, 'c'], [143.965, -117.054], [145.095, -117.802, 'c'], [146.25, -117.531, 'c'], [147.142, -117.227], [147.48, -117.112, 'c'], [148.143, -116.865, 'c'], [148.448, -116.791], [149.574, -116.515, 'c'], [150.43, -116.035, 'c'], [151.609, -115.852], [151.723, -115.834, 'c'], [151.908, -116.174, 'c'], [151.98, -116.146], [153.103, -115.708, 'c'], [154.145, -115.764, 'c'], [154.801, -114.6], [154.936, -114.735, 'c'], [155.101, -114.973, 'c'], [155.183, -114.946], [156.21, -114.608, 'c'], [156.859, -113.853, 'c'], [157.96, -113.612], [158.445, -113.506, 'c'], [159.057, -112.88, 'c'], [159.633, -112.704], [162.025, -111.973, 'c'], [163.868, -110.444, 'c'], [166.062, -109.549], [166.821, -109.239, 'c'], [167.697, -109.005, 'c'], [168.33, -108.509]], -closed => 1, -fillcolor => "#cc7226", -filled => 1, -linecolor => "#cc7226");
-
-$zinc->add('curve',$top_group,[[91.696, -122.739], [89.178, -124.464, 'c'], [86.81, -125.57, 'c'], [84.368, -127.356], [84.187, -127.489, 'c'], [83.827, -127.319, 'c'], [83.625, -127.441], [82.618, -128.05, 'c'], [81.73, -128.631, 'c'], [80.748, -129.327], [80.209, -129.709, 'c'], [79.388, -129.698, 'c'], [78.88, -129.956], [76.336, -131.248, 'c'], [73.707, -131.806, 'c'], [71.2, -133], [71.882, -133.638, 'c'], [73.004, -133.394, 'c'], [73.6, -134.2], [73.795, -133.92, 'c'], [74.033, -133.636, 'c'], [74.386, -133.827], [76.064, -134.731, 'c'], [77.914, -134.884, 'c'], [79.59, -134.794], [81.294, -134.702, 'c'], [83.014, -134.397, 'c'], [84.789, -134.125], [85.096, -134.078, 'c'], [85.295, -133.555, 'c'], [85.618, -133.458], [87.846, -132.795, 'c'], [90.235, -133.32, 'c'], [92.354, -132.482], [93.945, -131.853, 'c'], [95.515, -131.03, 'c'], [96.754, -129.755], [97.006, -129.495, 'c'], [96.681, -129.194, 'c'], [96.401, -129], [96.789, -129.109, 'c'], [97.062, -128.903, 'c'], [97.173, -128.59], [97.257, -128.351, 'c'], [97.257, -128.049, 'c'], [97.173, -127.81], [97.061, -127.498, 'c'], [96.782, -127.397, 'c'], [96.408, -127.346], [95.001, -127.156, 'c'], [96.773, -128.536, 'c'], [96.073, -128.088], [94.8, -127.274, 'c'], [95.546, -125.868, 'c'], [94.801, -124.6], [94.521, -124.794, 'c'], [94.291, -125.012, 'c'], [94.401, -125.4], [94.635, -124.878, 'c'], [94.033, -124.588, 'c'], [93.865, -124.272], [93.48, -123.547, 'c'], [92.581, -122.132, 'c'], [91.696, -122.739]], -closed => 1, -fillcolor => "#cc7226", -filled => 1, -linecolor => "#cc7226");
-
-$zinc->add('curve',$top_group,[[59.198, -115.391], [56.044, -116.185, 'c'], [52.994, -116.07, 'c'], [49.978, -117.346], [49.911, -117.374, 'c'], [49.688, -117.027, 'c'], [49.624, -117.054], [48.258, -117.648, 'c'], [47.34, -118.614, 'c'], [46.264, -119.66], [45.351, -120.548, 'c'], [43.693, -120.161, 'c'], [42.419, -120.648], [42.095, -120.772, 'c'], [41.892, -121.284, 'c'], [41.591, -121.323], [40.372, -121.48, 'c'], [39.445, -122.429, 'c'], [38.4, -123], [40.736, -123.795, 'c'], [43.147, -123.764, 'c'], [45.609, -124.148], [45.722, -124.166, 'c'], [45.867, -123.845, 'c'], [46, -123.845], [46.136, -123.845, 'c'], [46.266, -124.066, 'c'], [46.4, -124.2], [46.595, -123.92, 'c'], [46.897, -123.594, 'c'], [47.154, -123.848], [47.702, -124.388, 'c'], [48.258, -124.198, 'c'], [48.798, -124.158], [48.942, -124.148, 'c'], [49.067, -123.845, 'c'], [49.2, -123.845], [49.336, -123.845, 'c'], [49.467, -124.156, 'c'], [49.6, -124.156], [49.736, -124.155, 'c'], [49.867, -123.845, 'c'], [50, -123.845], [50.136, -123.845, 'c'], [50.266, -124.066, 'c'], [50.4, -124.2], [51.092, -123.418, 'c'], [51.977, -123.972, 'c'], [52.799, -123.793], [53.837, -123.566, 'c'], [54.104, -122.418, 'c'], [55.178, -122.12], [59.893, -120.816, 'c'], [64.03, -118.671, 'c'], [68.393, -116.584], [68.7, -116.437, 'c'], [68.91, -116.189, 'c'], [68.8, -115.8], [69.067, -115.8, 'c'], [69.38, -115.888, 'c'], [69.57, -115.756], [70.628, -115.024, 'c'], [71.669, -114.476, 'c'], [72.366, -113.378], [72.582, -113.039, 'c'], [72.253, -112.632, 'c'], [72.02, -112.684], [67.591, -113.679, 'c'], [63.585, -114.287, 'c'], [59.198, -115.391]], -closed => 1, -fillcolor => "#cc7226", -filled => 1, -linecolor => "#cc7226");
-
-$zinc->add('curve',$top_group,[[45.338, -71.179], [43.746, -72.398, 'c'], [43.162, -74.429, 'c'], [42.034, -76.221], [41.82, -76.561, 'c'], [42.094, -76.875, 'c'], [42.411, -76.964], [42.971, -77.123, 'c'], [43.514, -76.645, 'c'], [43.923, -76.443], [45.668, -75.581, 'c'], [47.203, -74.339, 'c'], [49.2, -74.2], [51.19, -71.966, 'c'], [55.45, -71.581, 'c'], [55.457, -68.2], [55.458, -67.341, 'c'], [54.03, -68.259, 'c'], [53.6, -67.4], [51.149, -68.403, 'c'], [48.76, -68.3, 'c'], [46.38, -69.767], [45.763, -70.148, 'c'], [46.093, -70.601, 'c'], [45.338, -71.179]], -closed => 1, -fillcolor => "#cc7226", -filled => 1, -linecolor => "#cc7226");
-
-$zinc->add('curve',$top_group,[[17.8, -123.756], [17.935, -123.755, 'c'], [24.966, -123.522, 'c'], [24.949, -123.408], [24.904, -123.099, 'c'], [17.174, -122.05, 'c'], [16.81, -122.22], [16.646, -122.296, 'c'], [9.134, -119.866, 'c'], [9, -120], [9.268, -120.135, 'c'], [17.534, -123.756, 'c'], [17.8, -123.756]], -closed => 1, -fillcolor => "#cc7226", -filled => 1, -linecolor => "#cc7226");
-
-$zinc->add('curve',$top_group,[[33.2, -114], [33.2, -114, 'c'], [18.4, -112.2, 'c'], [14, -111], [9.6, -109.8, 'c'], [-9, -102.2, 'c'], [-12, -100.2], [-12, -100.2, 'c'], [-25.4, -94.8, 'c'], [-42.4, -74.8], [-42.4, -74.8, 'c'], [-34.8, -78.2, 'c'], [-32.6, -81], [-32.6, -81, 'c'], [-19, -93.6, 'c'], [-19.2, -91], [-19.2, -91, 'c'], [-7, -99.6, 'c'], [-7.6, -97.4], [-7.6, -97.4, 'c'], [16.8, -108.6, 'c'], [14.8, -105.4], [14.8, -105.4, 'c'], [36.4, -110, 'c'], [35.4, -108], [35.4, -108, 'c'], [54.2, -103.6, 'c'], [51.4, -103.4], [51.4, -103.4, 'c'], [45.6, -102.2, 'c'], [52, -98.6], [52, -98.6, 'c'], [48.6, -94.2, 'c'], [43.2, -98.2], [37.8, -102.2, 'c'], [40.8, -100, 'c'], [35.8, -99], [35.8, -99, 'c'], [33.2, -98.2, 'c'], [28.6, -102.2], [28.6, -102.2, 'c'], [23, -106.8, 'c'], [14.2, -103.2], [14.2, -103.2, 'c'], [-16.4, -90.6, 'c'], [-18.4, -90], [-18.4, -90, 'c'], [-22, -87.2, 'c'], [-24.4, -83.6], [-24.4, -83.6, 'c'], [-30.2, -79.2, 'c'], [-33.2, -77.8], [-33.2, -77.8, 'c'], [-46, -66.2, 'c'], [-47.2, -64.8], [-47.2, -64.8, 'c'], [-50.6, -59.6, 'c'], [-51.4, -59.2], [-51.4, -59.2, 'c'], [-45, -63, 'c'], [-43, -65], [-43, -65, 'c'], [-29, -75, 'c'], [-23.6, -75.8], [-23.6, -75.8, 'c'], [-19.2, -78.8, 'c'], [-18.4, -80.2], [-18.4, -80.2, 'c'], [-4, -89.4, 'c'], [0.2, -89.4], [0.2, -89.4, 'c'], [9.4, -84.2, 'c'], [11.8, -91.2], [11.8, -91.2, 'c'], [17.6, -93, 'c'], [23.2, -91.8], [23.2, -91.8, 'c'], [26.4, -94.4, 'c'], [25.6, -96.6], [25.6, -96.6, 'c'], [27.2, -98.4, 'c'], [28.2, -94.6], [28.2, -94.6, 'c'], [31.6, -91, 'c'], [36.4, -93], [36.4, -93, 'c'], [40.4, -93.2, 'c'], [38.4, -90.8], [38.4, -90.8, 'c'], [34, -87, 'c'], [22.2, -86.8], [22.2, -86.8, 'c'], [9.8, -86.2, 'c'], [-6.6, -78.6], [-6.6, -78.6, 'c'], [-36.4, -68.2, 'c'], [-45.6, -57.8], [-45.6, -57.8, 'c'], [-52, -49, 'c'], [-57.4, -47.8], [-57.4, -47.8, 'c'], [-63.2, -47, 'c'], [-69.2, -39.6], [-69.2, -39.6, 'c'], [-59.4, -45.4, 'c'], [-50.4, -45.4], [-50.4, -45.4, 'c'], [-46.4, -47.8, 'c'], [-50.2, -44.2], [-50.2, -44.2, 'c'], [-53.8, -36.6, 'c'], [-52.2, -31.2], [-52.2, -31.2, 'c'], [-52.8, -26, 'c'], [-53.6, -24.4], [-53.6, -24.4, 'c'], [-61.4, -11.6, 'c'], [-61.4, -9.2], [-61.4, -6.8, 'c'], [-60.2, 3, 'c'], [-59.8, 3.6], [-59.4, 4.2, 'c'], [-60.8, 2, 'c'], [-57, 4.4], [-53.2, 6.8, 'c'], [-50.4, 8.4, 'c'], [-49.6, 11.2], [-48.8, 14, 'c'], [-51.6, 5.8, 'c'], [-51.8, 4], [-52, 2.2, 'c'], [-56.2, -5, 'c'], [-55.4, -7.4], [-55.4, -7.4, 'c'], [-54.4, -6.4, 'c'], [-53.6, -5], [-53.6, -5, 'c'], [-54.2, -5.6, 'c'], [-53.6, -9.2], [-53.6, -9.2, 'c'], [-52.8, -14.4, 'c'], [-51.4, -17.6], [-50, -20.8, 'c'], [-48, -24.6, 'c'], [-47.6, -25.4], [-47.2, -26.2, 'c'], [-47.2, -32, 'c'], [-45.8, -29.4], [-42.4, -26.8], [-42.4, -26.8, 'c'], [-45.2, -29.4, 'c'], [-43, -31.6], [-43, -31.6, 'c'], [-44, -37.2, 'c'], [-42.2, -39.8], [-42.2, -39.8, 'c'], [-35.2, -48.2, 'c'], [-33.6, -49.2], [-32, -50.2, 'c'], [-33.4, -49.8, 'c'], [-33.4, -49.8], [-33.4, -49.8, 'c'], [-27.4, -54, 'c'], [-33.2, -52.4], [-33.2, -52.4, 'c'], [-37.2, -50.8, 'c'], [-40.2, -50.8], [-40.2, -50.8, 'c'], [-47.8, -48.8, 'c'], [-43.8, -53], [-39.8, -57.2, 'c'], [-29.8, -62.6, 'c'], [-26, -62.4], [-25.2, -60.8], [-14, -63.2], [-15.2, -62.4], [-15.2, -62.4, 'c'], [-15.4, -62.6, 'c'], [-11.2, -63], [-7, -63.4, 'c'], [-1.2, -62, 'c'], [0.2, -63.8], [1.6, -65.6, 'c'], [5, -66.6, 'c'], [4.6, -65.2], [4.2, -63.8, 'c'], [4, -61.8, 'c'], [4, -61.8], [4, -61.8, 'c'], [9, -67.6, 'c'], [8.4, -65.4], [7.8, -63.2, 'c'], [-0.4, -58, 'c'], [-1.8, -51.8], [8.6, -60], [12.2, -63], [12.2, -63, 'c'], [15.8, -60.8, 'c'], [16, -62.4], [16.2, -64, 'c'], [20.8, -69.8, 'c'], [22, -69.6], [23.2, -69.4, 'c'], [25.2, -72.2, 'c'], [25, -69.6], [24.8, -67, 'c'], [32.4, -61.6, 'c'], [32.4, -61.6], [32.4, -61.6, 'c'], [35.6, -63.4, 'c'], [37, -62], [38.4, -60.6, 'c'], [42.6, -81.8, 'c'], [42.6, -81.8], [67.6, -92.4], [111.201, -95.8], [94.201, -102.6], [33.2, -114]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[20.895, 54.407], [22.437, 55.87, 'c'], [49.4, 84.8, 'c'], [49.4, 84.8], [84.6, 121.401, 'c'], [56.6, 87.2, 'c'], [56.6, 87.2], [49, 82.4, 'c'], [39.8, 63.6, 'c'], [39.8, 63.6], [38.6, 60.8, 'c'], [53.8, 70.8, 'c'], [53.8, 70.8], [57.8, 71.6, 'c'], [71.4, 90.8, 'c'], [71.4, 90.8], [64.6, 88.4, 'c'], [69.4, 95.6, 'c'], [69.4, 95.6], [72.2, 97.6, 'c'], [92.601, 113.201, 'c'], [92.601, 113.201], [96.201, 117.201, 'c'], [100.201, 118.801, 'c'], [100.201, 118.801], [114.201, 113.601, 'c'], [107.801, 126.801, 'c'], [107.801, 126.801], [110.201, 133.601, 'c'], [115.801, 122.001, 'c'], [115.801, 122.001], [127.001, 105.2, 'c'], [110.601, 107.601, 'c'], [110.601, 107.601], [80.6, 110.401, 'c'], [73.8, 94.4, 'c'], [73.8, 94.4], [71.4, 92, 'c'], [80.2, 94.4, 'c'], [80.2, 94.4], [88.601, 96.4, 'c'], [73, 82, 'c'], [73, 82], [75.4, 82, 'c'], [84.6, 88.8, 'c'], [84.6, 88.8], [95.001, 98, 'c'], [97.001, 96, 'c'], [97.001, 96], [115.001, 87.2, 'c'], [125.401, 94.8, 'c'], [125.401, 94.8], [127.401, 96.4, 'c'], [121.801, 103.2, 'c'], [123.401, 108.401], [125.001, 113.601, 'c'], [129.801, 126.001, 'c'], [129.801, 126.001], [127.401, 127.601, 'c'], [127.801, 138.401, 'c'], [127.801, 138.401], [144.601, 161.601, 'c'], [135.001, 159.601, 'c'], [135.001, 159.601], [119.401, 159.201, 'c'], [134.201, 166.801, 'c'], [134.201, 166.801], [137.401, 168.801, 'c'], [146.201, 176.001, 'c'], [146.201, 176.001], [143.401, 174.801, 'c'], [141.801, 180.001, 'c'], [141.801, 180.001], [146.601, 184.001, 'c'], [143.801, 188.801, 'c'], [143.801, 188.801], [137.801, 190.001, 'c'], [136.601, 194.001, 'c'], [136.601, 194.001], [143.401, 202.001, 'c'], [133.401, 202.401, 'c'], [133.401, 202.401], [137.001, 206.801, 'c'], [132.201, 218.801, 'c'], [132.201, 218.801], [127.401, 218.801, 'c'], [121.001, 224.401, 'c'], [121.001, 224.401], [123.401, 229.201, 'c'], [113.001, 234.801, 'c'], [113.001, 234.801], [104.601, 236.401, 'c'], [107.401, 243.201, 'c'], [107.401, 243.201], [99.401, 249.201, 'c'], [97.001, 265.201, 'c'], [97.001, 265.201], [96.201, 275.601, 'c'], [93.801, 278.801, 'c'], [99.001, 276.801], [104.201, 274.801, 'c'], [103.401, 262.401, 'c'], [103.401, 262.401], [98.601, 246.801, 'c'], [141.401, 230.801, 'c'], [141.401, 230.801], [145.401, 229.201, 'c'], [146.201, 224.001, 'c'], [146.201, 224.001], [148.201, 224.401, 'c'], [157.001, 232.001, 'c'], [157.001, 232.001], [164.601, 243.201, 'c'], [165.001, 234.001, 'c'], [165.001, 234.001], [166.201, 230.401, 'c'], [164.601, 224.401, 'c'], [164.601, 224.401], [170.601, 202.801, 'c'], [156.601, 196.401, 'c'], [156.601, 196.401], [146.601, 162.801, 'c'], [160.601, 171.201, 'c'], [160.601, 171.201], [163.401, 176.801, 'c'], [174.201, 182.001, 'c'], [174.201, 182.001], [177.801, 179.601], [176.201, 174.801, 'c'], [184.601, 168.801, 'c'], [184.601, 168.801], [187.401, 175.201, 'c'], [193.401, 167.201, 'c'], [193.401, 167.201], [197.001, 142.801, 'c'], [209.401, 157.201, 'c'], [209.401, 157.201], [213.401, 158.401, 'c'], [214.601, 151.601, 'c'], [214.601, 151.601], [218.201, 141.201, 'c'], [214.601, 127.601, 'c'], [214.601, 127.601], [218.201, 127.201, 'c'], [227.801, 133.201, 'c'], [227.801, 133.201], [230.601, 129.601, 'c'], [221.401, 112.801, 'c'], [225.401, 115.201], [229.401, 117.601, 'c'], [233.801, 119.201, 'c'], [233.801, 119.201], [234.601, 117.201, 'c'], [224.601, 104.801, 'c'], [224.601, 104.801], [220.201, 102, 'c'], [215.001, 81.6, 'c'], [215.001, 81.6], [222.201, 85.2, 'c'], [212.201, 70, 'c'], [212.201, 70], [212.201, 66.8, 'c'], [218.201, 55.6, 'c'], [218.201, 55.6], [217.401, 48.8, 'c'], [218.201, 49.2, 'c'], [218.201, 49.2], [221.001, 50.4, 'c'], [229.001, 52, 'c'], [222.201, 45.6], [215.401, 39.2, 'c'], [223.001, 34.4, 'c'], [223.001, 34.4], [227.401, 31.6, 'c'], [213.801, 32, 'c'], [213.801, 32], [208.601, 27.6, 'c'], [209.001, 23.6, 'c'], [209.001, 23.6], [217.001, 25.6, 'c'], [202.601, 11.2, 'c'], [200.201, 7.6], [197.801, 4, 'c'], [207.401, -1.2, 'c'], [207.401, -1.2], [220.601, -4.8, 'c'], [209.001, -8, 'c'], [209.001, -8], [189.401, -7.6, 'c'], [200.201, -18.4, 'c'], [200.201, -18.4], [206.201, -18, 'c'], [204.601, -20.4, 'c'], [204.601, -20.4], [199.401, -21.6, 'c'], [189.801, -28, 'c'], [189.801, -28], [185.801, -31.6, 'c'], [189.401, -30.8, 'c'], [189.401, -30.8], [206.201, -29.6, 'c'], [177.401, -40.8, 'c'], [177.401, -40.8], [185.401, -40.8, 'c'], [167.401, -51.2, 'c'], [167.401, -51.2], [165.401, -52.8, 'c'], [162.201, -60.4, 'c'], [162.201, -60.4], [156.201, -65.6, 'c'], [151.401, -72.4, 'c'], [151.401, -72.4], [151.001, -76.8, 'c'], [146.201, -81.6, 'c'], [146.201, -81.6], [134.601, -95.2, 'c'], [129.001, -94.8, 'c'], [129.001, -94.8], [114.201, -98.4, 'c'], [109.001, -97.6, 'c'], [109.001, -97.6], [56.2, -93.2], [29.8, -80.4, 'c'], [37.6, -59.4, 'c'], [37.6, -59.4], [44, -51, 'c'], [53.2, -54.8, 'c'], [53.2, -54.8], [57.8, -61, 'c'], [69.4, -58.8, 'c'], [69.4, -58.8], [89.801, -55.6, 'c'], [87.201, -59.2, 'c'], [87.201, -59.2], [84.801, -63.8, 'c'], [68.6, -70, 'c'], [68.4, -70.6], [68.2, -71.2, 'c'], [59.4, -74.6, 'c'], [59.4, -74.6], [56.4, -75.8, 'c'], [52, -85, 'c'], [52, -85], [48.8, -88.4, 'c'], [64.6, -82.6, 'c'], [64.6, -82.6], [63.4, -81.6, 'c'], [70.8, -77.6, 'c'], [70.8, -77.6], [88.201, -78.6, 'c'], [98.801, -67.8, 'c'], [98.801, -67.8], [109.601, -51.2, 'c'], [109.801, -59.4, 'c'], [109.801, -59.4], [112.601, -68.8, 'c'], [100.801, -90, 'c'], [100.801, -90], [101.201, -92, 'c'], [109.401, -85.4, 'c'], [109.401, -85.4], [110.801, -87.4, 'c'], [111.601, -81.6, 'c'], [111.601, -81.6], [111.801, -79.2, 'c'], [115.601, -71.2, 'c'], [115.601, -71.2], [118.401, -58.2, 'c'], [122.001, -65.6, 'c'], [122.001, -65.6], [126.601, -56.2], [128.001, -53.6, 'c'], [122.001, -46, 'c'], [122.001, -46], [121.801, -43.2, 'c'], [122.601, -43.4, 'c'], [117.001, -35.8], [111.401, -28.2, 'c'], [114.801, -23.8, 'c'], [114.801, -23.8], [113.401, -17.2, 'c'], [122.201, -17.6, 'c'], [122.201, -17.6], [124.801, -15.4, 'c'], [128.201, -15.4, 'c'], [128.201, -15.4], [130.001, -13.4, 'c'], [132.401, -14, 'c'], [132.401, -14], [134.001, -17.8, 'c'], [140.201, -15.8, 'c'], [140.201, -15.8], [141.601, -18.2, 'c'], [149.801, -18.6, 'c'], [149.801, -18.6], [150.801, -21.2, 'c'], [151.201, -22.8, 'c'], [154.601, -23.4], [158.001, -24, 'c'], [133.401, -67, 'c'], [133.401, -67], [139.801, -67.8, 'c'], [131.601, -80.2, 'c'], [131.601, -80.2], [129.401, -86.8, 'c'], [140.801, -72.2, 'c'], [143.001, -70.8], [145.201, -69.4, 'c'], [146.201, -67.2, 'c'], [144.601, -67.4], [143.001, -67.6, 'c'], [141.201, -65.4, 'c'], [142.601, -65.2], [144.001, -65, 'c'], [157.001, -50, 'c'], [160.401, -39.8], [163.801, -29.6, 'c'], [169.801, -25.6, 'c'], [176.001, -19.6], [182.201, -13.6, 'c'], [181.401, 10.6, 'c'], [181.401, 10.6], [181.001, 19.4, 'c'], [187.001, 30, 'c'], [187.001, 30], [189.001, 33.8, 'c'], [184.801, 52, 'c'], [184.801, 52], [182.801, 54.2, 'c'], [184.201, 55, 'c'], [184.201, 55], [185.201, 56.2, 'c'], [192.001, 69.4, 'c'], [192.001, 69.4], [190.201, 69.2, 'c'], [193.801, 72.8, 'c'], [193.801, 72.8], [199.001, 78.8, 'c'], [192.601, 75.8, 'c'], [192.601, 75.8], [186.601, 74.2, 'c'], [193.601, 84, 'c'], [193.601, 84], [194.801, 85.8, 'c'], [185.801, 81.2, 'c'], [185.801, 81.2], [176.601, 80.6, 'c'], [188.201, 87.8, 'c'], [188.201, 87.8], [196.801, 95, 'c'], [185.401, 90.6, 'c'], [185.401, 90.6], [180.801, 88.8, 'c'], [184.001, 95.6, 'c'], [184.001, 95.6], [187.201, 97.2, 'c'], [204.401, 104.2, 'c'], [204.401, 104.2], [204.801, 108.001, 'c'], [201.801, 113.001, 'c'], [201.801, 113.001], [202.201, 117.001, 'c'], [200.001, 120.401, 'c'], [200.001, 120.401], [198.801, 128.601, 'c'], [198.201, 129.401, 'c'], [198.201, 129.401], [194.001, 129.601, 'c'], [186.601, 143.401, 'c'], [186.601, 143.401], [184.801, 146.001, 'c'], [174.601, 158.001, 'c'], [174.601, 158.001], [172.601, 165.001, 'c'], [154.601, 157.801, 'c'], [154.601, 157.801], [148.001, 161.201, 'c'], [150.001, 157.801, 'c'], [150.001, 157.801], [149.601, 155.601, 'c'], [154.401, 149.601, 'c'], [154.401, 149.601], [161.401, 147.001, 'c'], [158.801, 136.201, 'c'], [158.801, 136.201], [162.801, 134.801, 'c'], [151.601, 132.001, 'c'], [151.801, 130.801], [152.001, 129.601, 'c'], [157.801, 128.201, 'c'], [157.801, 128.201], [165.801, 126.201, 'c'], [161.401, 123.801, 'c'], [161.401, 123.801], [160.801, 119.801, 'c'], [163.801, 114.201, 'c'], [163.801, 114.201], [175.401, 113.401, 'c'], [163.801, 97.2, 'c'], [163.801, 97.2], [153.001, 89.6, 'c'], [152.001, 83.8, 'c'], [152.001, 83.8], [164.601, 75.6, 'c'], [156.401, 63.2, 'c'], [156.601, 59.6], [156.801, 56, 'c'], [158.001, 34.4, 'c'], [158.001, 34.4], [156.001, 28.2, 'c'], [153.001, 14.6, 'c'], [153.001, 14.6], [155.201, 9.4, 'c'], [162.601, -3.2, 'c'], [162.601, -3.2], [165.401, -7.4, 'c'], [174.201, -12.2, 'c'], [172.001, -15.2], [169.801, -18.2, 'c'], [162.001, -16.4, 'c'], [162.001, -16.4], [154.201, -17.8, 'c'], [154.801, -12.6, 'c'], [154.801, -12.6], [153.201, -11.6, 'c'], [152.401, -6.6, 'c'], [152.401, -6.6], [151.68, 1.333, 'c'], [142.801, 7.6, 'c'], [142.801, 7.6], [131.601, 13.8, 'c'], [140.801, 17.8, 'c'], [140.801, 17.8], [146.801, 24.4, 'c'], [137.001, 24.6, 'c'], [137.001, 24.6], [126.001, 22.8, 'c'], [134.201, 33, 'c'], [134.201, 33], [145.001, 45.8, 'c'], [142.001, 48.6, 'c'], [142.001, 48.6], [131.801, 49.6, 'c'], [144.401, 58.8, 'c'], [144.401, 58.8], [144.401, 58.8, 'c'], [143.601, 56.8, 'c'], [143.801, 58.6], [144.001, 60.4, 'c'], [147.001, 64.6, 'c'], [147.801, 66.6], [148.601, 68.6, 'c'], [144.601, 68.8, 'c'], [144.601, 68.8], [145.201, 78.4, 'c'], [129.801, 74.2, 'c'], [129.801, 74.2], [129.801, 74.2, 'c'], [129.801, 74.2, 'c'], [128.201, 74.4], [126.601, 74.6, 'c'], [115.401, 73.8, 'c'], [109.601, 71.6], [103.801, 69.4, 'c'], [97.001, 69.4, 'c'], [97.001, 69.4], [97.001, 69.4, 'c'], [93.001, 71.2, 'c'], [85.4, 71], [77.8, 70.8, 'c'], [69.8, 73.6, 'c'], [69.8, 73.6], [65.4, 73.2, 'c'], [74, 68.8, 'c'], [74.2, 69], [74.4, 69.2, 'c'], [80, 63.6, 'c'], [72, 64.2], [50.203, 65.835, 'c'], [39.4, 55.6, 'c'], [39.4, 55.6], [37.4, 54.2, 'c'], [34.8, 51.4, 'c'], [34.8, 51.4], [24.8, 49.4, 'c'], [36.2, 63.8, 'c'], [36.2, 63.8], [37.4, 65.2, 'c'], [36, 66.2, 'c'], [36, 66.2], [35.2, 64.6, 'c'], [27.4, 59.2, 'c'], [27.4, 59.2], [24.589, 58.227, 'c'], [23.226, 56.893, 'c'], [20.895, 54.407]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-3, 42.8], [-3, 42.8, 'c'], [8.6, 48.4, 'c'], [11.2, 51.2], [13.8, 54, 'c'], [27.8, 65.4, 'c'], [27.8, 65.4], [27.8, 65.4, 'c'], [22.4, 63.4, 'c'], [19.8, 61.6], [17.2, 59.8, 'c'], [6.4, 51.6, 'c'], [6.4, 51.6], [6.4, 51.6, 'c'], [2.6, 45.6, 'c'], [-3, 42.8]], -closed => 1, -fillcolor => "#4c0000", -filled => 1, -linecolor => "#4c0000");
-
-$zinc->add('curve',$top_group,[[-61.009, 11.603], [-60.672, 11.455, 'c'], [-61.196, 8.743, 'c'], [-61.4, 8.2], [-62.422, 5.474, 'c'], [-71.4, 4, 'c'], [-71.4, 4], [-71.627, 5.365, 'c'], [-71.682, 6.961, 'c'], [-71.576, 8.599], [-71.576, 8.599, 'c'], [-66.708, 14.118, 'c'], [-61.009, 11.603]], -closed => 1, -fillcolor => "#99cc32", -filled => 1, -linecolor => "#99cc32");
-
-$zinc->add('curve',$top_group,[[-61.009, 11.403], [-61.458, 11.561, 'c'], [-61.024, 8.669, 'c'], [-61.2, 8.2], [-62.222, 5.474, 'c'], [-71.4, 3.9, 'c'], [-71.4, 3.9], [-71.627, 5.265, 'c'], [-71.682, 6.861, 'c'], [-71.576, 8.499], [-71.576, 8.499, 'c'], [-67.308, 13.618, 'c'], [-61.009, 11.403]], -closed => 1, -fillcolor => "#659900", -filled => 1, -linecolor => "#659900");
-
-$zinc->add('curve',$top_group,[[-65.4, 11.546], [-66.025, 11.546, 'c'], [-66.531, 10.406, 'c'], [-66.531, 9], [-66.531, 7.595, 'c'], [-66.025, 6.455, 'c'], [-65.4, 6.455], [-64.775, 6.455, 'c'], [-64.268, 7.595, 'c'], [-64.268, 9], [-64.268, 10.406, 'c'], [-64.775, 11.546, 'c'], [-65.4, 11.546]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-65.4, 9]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-111, 109.601], [-111, 109.601, 'c'], [-116.6, 119.601, 'c'], [-91.8, 113.601], [-91.8, 113.601, 'c'], [-77.8, 112.401, 'c'], [-75.4, 110.001], [-74.2, 110.801, 'c'], [-65.834, 113.734, 'c'], [-63, 114.401], [-56.2, 116.001, 'c'], [-47.8, 106, 'c'], [-47.8, 106], [-47.8, 106, 'c'], [-43.2, 95.5, 'c'], [-40.4, 95.5], [-37.6, 95.5, 'c'], [-40.8, 97.1, 'c'], [-40.8, 97.1], [-40.8, 97.1, 'c'], [-47.4, 107.201, 'c'], [-47, 108.801], [-47, 108.801, 'c'], [-52.2, 128.801, 'c'], [-68.2, 129.601], [-68.2, 129.601, 'c'], [-84.35, 130.551, 'c'], [-83, 136.401], [-83, 136.401, 'c'], [-74.2, 134.001, 'c'], [-71.8, 136.401], [-71.8, 136.401, 'c'], [-61, 136.001, 'c'], [-69, 142.401], [-75.8, 154.001], [-75.8, 154.001, 'c'], [-75.66, 157.919, 'c'], [-85.8, 154.401], [-95.6, 151.001, 'c'], [-105.9, 138.101, 'c'], [-105.9, 138.101], [-105.9, 138.101, 'c'], [-121.85, 123.551, 'c'], [-111, 109.601]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-112.2, 113.601], [-112.2, 113.601, 'c'], [-114.2, 123.201, 'c'], [-77.4, 112.801], [-77.4, 112.801, 'c'], [-73, 112.801, 'c'], [-70.6, 113.601], [-68.2, 114.401, 'c'], [-56.2, 117.201, 'c'], [-54.2, 116.001], [-54.2, 116.001, 'c'], [-61.4, 129.601, 'c'], [-73, 128.001], [-73, 128.001, 'c'], [-86.2, 129.601, 'c'], [-85.8, 134.401], [-85.8, 134.401, 'c'], [-81.8, 141.601, 'c'], [-77, 144.001], [-77, 144.001, 'c'], [-74.2, 146.401, 'c'], [-74.6, 149.601], [-75, 152.801, 'c'], [-77.8, 154.401, 'c'], [-79.8, 155.201], [-81.8, 156.001, 'c'], [-85, 152.801, 'c'], [-86.6, 152.801], [-88.2, 152.801, 'c'], [-96.6, 146.401, 'c'], [-101, 141.601], [-105.4, 136.801, 'c'], [-113.8, 124.801, 'c'], [-113.4, 122.001], [-113, 119.201, 'c'], [-112.2, 113.601, 'c'], [-112.2, 113.601]], -closed => 1, -fillcolor => "#e59999", -filled => 1, -linecolor => "#e59999");
-
-$zinc->add('curve',$top_group,[[-109, 131.051], [-106.4, 135.001, 'c'], [-103.2, 139.201, 'c'], [-101, 141.601], [-96.6, 146.401, 'c'], [-88.2, 152.801, 'c'], [-86.6, 152.801], [-85, 152.801, 'c'], [-81.8, 156.001, 'c'], [-79.8, 155.201], [-77.8, 154.401, 'c'], [-75, 152.801, 'c'], [-74.6, 149.601], [-74.2, 146.401, 'c'], [-77, 144.001, 'c'], [-77, 144.001], [-80.066, 142.468, 'c'], [-82.806, 138.976, 'c'], [-84.385, 136.653], [-84.385, 136.653, 'c'], [-84.2, 139.201, 'c'], [-89.4, 138.401], [-94.6, 137.601, 'c'], [-99.8, 134.801, 'c'], [-101.4, 131.601], [-103, 128.401, 'c'], [-105.4, 126.001, 'c'], [-103.8, 129.601], [-102.2, 133.201, 'c'], [-99.8, 136.801, 'c'], [-98.2, 137.201], [-96.6, 137.601, 'c'], [-97, 138.801, 'c'], [-99.4, 138.401], [-101.8, 138.001, 'c'], [-104.6, 137.601, 'c'], [-109, 132.401]], -closed => 1, -fillcolor => "#b26565", -filled => 1, -linecolor => "#b26565");
-
-$zinc->add('curve',$top_group,[[-111.6, 110.001], [-111.6, 110.001, 'c'], [-109.8, 96.4, 'c'], [-108.6, 92.4], [-108.6, 92.4, 'c'], [-109.4, 85.6, 'c'], [-107, 81.4], [-104.6, 77.2, 'c'], [-102.6, 71, 'c'], [-99.6, 65.6], [-96.6, 60.2, 'c'], [-96.4, 56.2, 'c'], [-92.4, 54.6], [-88.4, 53, 'c'], [-82.4, 44.4, 'c'], [-79.6, 43.4], [-76.8, 42.4, 'c'], [-77, 43.2, 'c'], [-77, 43.2], [-77, 43.2, 'c'], [-70.2, 28.4, 'c'], [-56.6, 32.4], [-56.6, 32.4, 'c'], [-72.8, 29.6, 'c'], [-57, 20.2], [-57, 20.2, 'c'], [-61.8, 21.3, 'c'], [-58.5, 14.3], [-56.299, 9.632, 'c'], [-56.8, 16.4, 'c'], [-67.8, 28.2], [-67.8, 28.2, 'c'], [-72.8, 36.8, 'c'], [-78, 39.8], [-83.2, 42.8, 'c'], [-95.2, 49.8, 'c'], [-96.4, 53.6], [-97.6, 57.4, 'c'], [-100.8, 63.2, 'c'], [-102.8, 64.8], [-104.8, 66.4, 'c'], [-107.6, 70.6, 'c'], [-108, 74], [-108, 74, 'c'], [-109.2, 78, 'c'], [-110.6, 79.2], [-112, 80.4, 'c'], [-112.2, 83.6, 'c'], [-112.2, 85.6], [-112.2, 87.6, 'c'], [-114.2, 90.4, 'c'], [-114, 92.8], [-114, 92.8, 'c'], [-113.2, 111.801, 'c'], [-113.6, 113.801], [-111.6, 110.001]], -closed => 1, -fillcolor => "#992600", -filled => 1, -linecolor => "#992600");
-
-$zinc->add('curve',$top_group,[[-120.2, 114.601], [-120.2, 114.601, 'c'], [-122.2, 113.201, 'c'], [-126.6, 119.201], [-126.6, 119.201, 'c'], [-119.3, 152.201, 'c'], [-119.3, 153.601], [-119.3, 153.601, 'c'], [-118.2, 151.501, 'c'], [-119.5, 144.301], [-120.8, 137.101, 'c'], [-121.7, 124.401, 'c'], [-121.7, 124.401], [-120.2, 114.601]], -closed => 1, -fillcolor => "#ffffff", -filled => 1, -linecolor => "#ffffff");
-
-$zinc->add('curve',$top_group,[[-98.6, 54], [-98.6, 54, 'c'], [-116.2, 57.2, 'c'], [-115.8, 86.4], [-116.6, 111.201], [-116.6, 111.201, 'c'], [-117.8, 85.6, 'c'], [-119, 84], [-120.2, 82.4, 'c'], [-116.2, 71.2, 'c'], [-119.4, 77.2], [-119.4, 77.2, 'c'], [-133.4, 91.2, 'c'], [-125.4, 112.401], [-125.4, 112.401, 'c'], [-123.9, 115.701, 'c'], [-126.9, 111.101], [-126.9, 111.101, 'c'], [-131.5, 98.5, 'c'], [-130.4, 92.1], [-130.4, 92.1, 'c'], [-130.2, 89.9, 'c'], [-128.3, 87.1], [-128.3, 87.1, 'c'], [-119.7, 75.4, 'c'], [-117, 73.1], [-117, 73.1, 'c'], [-115.2, 58.7, 'c'], [-99.8, 53.5], [-99.8, 53.5, 'c'], [-94.1, 51.2, 'c'], [-98.6, 54]], -closed => 1, -fillcolor => "#992600", -filled => 1, -linecolor => "#992600");
-
-$zinc->add('curve',$top_group,[[40.8, -12.2], [41.46, -12.554, 'c'], [41.451, -13.524, 'c'], [42.031, -13.697], [43.18, -14.041, 'c'], [43.344, -15.108, 'c'], [43.862, -15.892], [44.735, -17.211, 'c'], [44.928, -18.744, 'c'], [45.51, -20.235], [45.782, -20.935, 'c'], [45.809, -21.89, 'c'], [45.496, -22.55], [44.322, -25.031, 'c'], [43.62, -27.48, 'c'], [42.178, -29.906], [41.91, -30.356, 'c'], [41.648, -31.15, 'c'], [41.447, -31.748], [40.984, -33.132, 'c'], [39.727, -34.123, 'c'], [38.867, -35.443], [38.579, -35.884, 'c'], [39.104, -36.809, 'c'], [38.388, -36.893], [37.491, -36.998, 'c'], [36.042, -37.578, 'c'], [35.809, -36.552], [35.221, -33.965, 'c'], [36.232, -31.442, 'c'], [37.2, -29], [36.418, -28.308, 'c'], [36.752, -27.387, 'c'], [36.904, -26.62], [37.614, -23.014, 'c'], [36.416, -19.662, 'c'], [35.655, -16.188], [35.632, -16.084, 'c'], [35.974, -15.886, 'c'], [35.946, -15.824], [34.724, -13.138, 'c'], [33.272, -10.693, 'c'], [31.453, -8.312], [30.695, -7.32, 'c'], [29.823, -6.404, 'c'], [29.326, -5.341], [28.958, -4.554, 'c'], [28.55, -3.588, 'c'], [28.8, -2.6], [25.365, 0.18, 'c'], [23.115, 4.025, 'c'], [20.504, 7.871], [20.042, 8.551, 'c'], [20.333, 9.76, 'c'], [20.884, 10.029], [21.697, 10.427, 'c'], [22.653, 9.403, 'c'], [23.123, 8.557], [23.512, 7.859, 'c'], [23.865, 7.209, 'c'], [24.356, 6.566], [24.489, 6.391, 'c'], [24.31, 5.972, 'c'], [24.445, 5.851], [27.078, 3.504, 'c'], [28.747, 0.568, 'c'], [31.2, -1.8], [33.15, -2.129, 'c'], [34.687, -3.127, 'c'], [36.435, -4.14], [36.743, -4.319, 'c'], [37.267, -4.07, 'c'], [37.557, -4.265], [39.31, -5.442, 'c'], [39.308, -7.478, 'c'], [39.414, -9.388], [39.464, -10.272, 'c'], [39.66, -11.589, 'c'], [40.8, -12.2]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[31.959, -16.666], [32.083, -16.743, 'c'], [31.928, -17.166, 'c'], [32.037, -17.382], [32.199, -17.706, 'c'], [32.602, -17.894, 'c'], [32.764, -18.218], [32.873, -18.434, 'c'], [32.71, -18.814, 'c'], [32.846, -18.956], [35.179, -21.403, 'c'], [35.436, -24.427, 'c'], [34.4, -27.4], [35.424, -28.02, 'c'], [35.485, -29.282, 'c'], [35.06, -30.129], [34.207, -31.829, 'c'], [34.014, -33.755, 'c'], [33.039, -35.298], [32.237, -36.567, 'c'], [30.659, -37.811, 'c'], [29.288, -36.508], [28.867, -36.108, 'c'], [28.546, -35.321, 'c'], [28.824, -34.609], [28.888, -34.446, 'c'], [29.173, -34.3, 'c'], [29.146, -34.218], [29.039, -33.894, 'c'], [28.493, -33.67, 'c'], [28.487, -33.398], [28.457, -31.902, 'c'], [27.503, -30.391, 'c'], [28.133, -29.062], [28.905, -27.433, 'c'], [29.724, -25.576, 'c'], [30.4, -23.8], [29.166, -21.684, 'c'], [30.199, -19.235, 'c'], [28.446, -17.358], [28.31, -17.212, 'c'], [28.319, -16.826, 'c'], [28.441, -16.624], [28.733, -16.138, 'c'], [29.139, -15.732, 'c'], [29.625, -15.44], [29.827, -15.319, 'c'], [30.175, -15.317, 'c'], [30.375, -15.441], [30.953, -15.803, 'c'], [31.351, -16.29, 'c'], [31.959, -16.666]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[94.771, -26.977], [96.16, -25.185, 'c'], [96.45, -22.39, 'c'], [94.401, -21], [94.951, -17.691, 'c'], [98.302, -19.67, 'c'], [100.401, -20.2], [100.292, -20.588, 'c'], [100.519, -20.932, 'c'], [100.802, -20.937], [101.859, -20.952, 'c'], [102.539, -21.984, 'c'], [103.601, -21.8], [104.035, -23.357, 'c'], [105.673, -24.059, 'c'], [106.317, -25.439], [108.043, -29.134, 'c'], [107.452, -33.407, 'c'], [104.868, -36.653], [104.666, -36.907, 'c'], [104.883, -37.424, 'c'], [104.759, -37.786], [104.003, -39.997, 'c'], [101.935, -40.312, 'c'], [100.001, -41], [98.824, -44.875, 'c'], [98.163, -48.906, 'c'], [96.401, -52.6], [94.787, -52.85, 'c'], [94.089, -54.589, 'c'], [92.752, -55.309], [91.419, -56.028, 'c'], [90.851, -54.449, 'c'], [90.892, -53.403], [90.899, -53.198, 'c'], [91.351, -52.974, 'c'], [91.181, -52.609], [91.105, -52.445, 'c'], [90.845, -52.334, 'c'], [90.845, -52.2], [90.846, -52.065, 'c'], [91.067, -51.934, 'c'], [91.201, -51.8], [90.283, -50.98, 'c'], [88.86, -50.503, 'c'], [88.565, -49.358], [87.611, -45.648, 'c'], [90.184, -42.523, 'c'], [91.852, -39.322], [92.443, -38.187, 'c'], [91.707, -36.916, 'c'], [90.947, -35.708], [90.509, -35.013, 'c'], [90.617, -33.886, 'c'], [90.893, -33.03], [91.645, -30.699, 'c'], [93.236, -28.96, 'c'], [94.771, -26.977]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[57.611, -8.591], [56.124, -6.74, 'c'], [52.712, -4.171, 'c'], [55.629, -2.243], [55.823, -2.114, 'c'], [56.193, -2.11, 'c'], [56.366, -2.244], [58.387, -3.809, 'c'], [60.39, -4.712, 'c'], [62.826, -5.294], [62.95, -5.323, 'c'], [63.224, -4.856, 'c'], [63.593, -5.017], [65.206, -5.72, 'c'], [67.216, -5.662, 'c'], [68.4, -7], [72.167, -6.776, 'c'], [75.732, -7.892, 'c'], [79.123, -9.2], [80.284, -9.648, 'c'], [81.554, -10.207, 'c'], [82.755, -10.709], [84.131, -11.285, 'c'], [85.335, -12.213, 'c'], [86.447, -13.354], [86.58, -13.49, 'c'], [86.934, -13.4, 'c'], [87.201, -13.4], [87.161, -14.263, 'c'], [88.123, -14.39, 'c'], [88.37, -15.012], [88.462, -15.244, 'c'], [88.312, -15.64, 'c'], [88.445, -15.742], [90.583, -17.372, 'c'], [91.503, -19.39, 'c'], [90.334, -21.767], [90.049, -22.345, 'c'], [89.8, -22.963, 'c'], [89.234, -23.439], [88.149, -24.35, 'c'], [87.047, -23.496, 'c'], [86, -23.8], [85.841, -23.172, 'c'], [85.112, -23.344, 'c'], [84.726, -23.146], [83.867, -22.707, 'c'], [82.534, -23.292, 'c'], [81.675, -22.854], [80.313, -22.159, 'c'], [79.072, -21.99, 'c'], [77.65, -21.613], [77.338, -21.531, 'c'], [76.56, -21.627, 'c'], [76.4, -21], [76.266, -21.134, 'c'], [76.118, -21.368, 'c'], [76.012, -21.346], [74.104, -20.95, 'c'], [72.844, -20.736, 'c'], [71.543, -19.044], [71.44, -18.911, 'c'], [70.998, -19.09, 'c'], [70.839, -18.955], [69.882, -18.147, 'c'], [69.477, -16.913, 'c'], [68.376, -16.241], [68.175, -16.118, 'c'], [67.823, -16.286, 'c'], [67.629, -16.157], [66.983, -15.726, 'c'], [66.616, -15.085, 'c'], [65.974, -14.638], [65.645, -14.409, 'c'], [65.245, -14.734, 'c'], [65.277, -14.99], [65.522, -16.937, 'c'], [66.175, -18.724, 'c'], [65.6, -20.6], [67.677, -23.12, 'c'], [70.194, -25.069, 'c'], [72, -27.8], [72.015, -29.966, 'c'], [72.707, -32.112, 'c'], [72.594, -34.189], [72.584, -34.382, 'c'], [72.296, -35.115, 'c'], [72.17, -35.462], [71.858, -36.316, 'c'], [72.764, -37.382, 'c'], [71.92, -38.106], [70.516, -39.309, 'c'], [69.224, -38.433, 'c'], [68.4, -37], [66.562, -36.61, 'c'], [64.496, -35.917, 'c'], [62.918, -37.151], [61.911, -37.938, 'c'], [61.333, -38.844, 'c'], [60.534, -39.9], [59.549, -41.202, 'c'], [59.884, -42.638, 'c'], [59.954, -44.202], [59.96, -44.33, 'c'], [59.645, -44.466, 'c'], [59.645, -44.6], [59.646, -44.735, 'c'], [59.866, -44.866, 'c'], [60, -45], [59.294, -45.626, 'c'], [59.019, -46.684, 'c'], [58, -47], [58.305, -48.092, 'c'], [57.629, -48.976, 'c'], [56.758, -49.278], [54.763, -49.969, 'c'], [53.086, -48.057, 'c'], [51.194, -47.984], [50.68, -47.965, 'c'], [50.213, -49.003, 'c'], [49.564, -49.328], [49.132, -49.544, 'c'], [48.428, -49.577, 'c'], [48.066, -49.311], [47.378, -48.807, 'c'], [46.789, -48.693, 'c'], [46.031, -48.488], [44.414, -48.052, 'c'], [43.136, -46.958, 'c'], [41.656, -46.103], [40.171, -45.246, 'c'], [39.216, -43.809, 'c'], [38.136, -42.489], [37.195, -41.337, 'c'], [37.059, -38.923, 'c'], [38.479, -38.423], [40.322, -37.773, 'c'], [41.626, -40.476, 'c'], [43.592, -40.15], [43.904, -40.099, 'c'], [44.11, -39.788, 'c'], [44, -39.4], [44.389, -39.291, 'c'], [44.607, -39.52, 'c'], [44.8, -39.8], [45.658, -38.781, 'c'], [46.822, -38.444, 'c'], [47.76, -37.571], [48.73, -36.667, 'c'], [50.476, -37.085, 'c'], [51.491, -36.088], [53.02, -34.586, 'c'], [52.461, -31.905, 'c'], [54.4, -30.6], [53.814, -29.287, 'c'], [53.207, -28.01, 'c'], [52.872, -26.583], [52.59, -25.377, 'c'], [53.584, -24.18, 'c'], [54.795, -24.271], [56.053, -24.365, 'c'], [56.315, -25.124, 'c'], [56.8, -26.2], [57.067, -25.933, 'c'], [57.536, -25.636, 'c'], [57.495, -25.42], [57.038, -23.033, 'c'], [56.011, -21.04, 'c'], [55.553, -18.609], [55.494, -18.292, 'c'], [55.189, -18.09, 'c'], [54.8, -18.2], [54.332, -14.051, 'c'], [50.28, -11.657, 'c'], [47.735, -8.492], [47.332, -7.99, 'c'], [47.328, -6.741, 'c'], [47.737, -6.338], [49.14, -4.951, 'c'], [51.1, -6.497, 'c'], [52.8, -7], [53.013, -8.206, 'c'], [53.872, -9.148, 'c'], [55.204, -9.092], [55.46, -9.082, 'c'], [55.695, -9.624, 'c'], [56.019, -9.754], [56.367, -9.892, 'c'], [56.869, -9.668, 'c'], [57.155, -9.866], [58.884, -11.061, 'c'], [60.292, -12.167, 'c'], [62.03, -13.356], [62.222, -13.487, 'c'], [62.566, -13.328, 'c'], [62.782, -13.436], [63.107, -13.598, 'c'], [63.294, -13.985, 'c'], [63.617, -14.17], [63.965, -14.37, 'c'], [64.207, -14.08, 'c'], [64.4, -13.8], [63.754, -13.451, 'c'], [63.75, -12.494, 'c'], [63.168, -12.292], [62.393, -12.024, 'c'], [61.832, -11.511, 'c'], [61.158, -11.064], [60.866, -10.871, 'c'], [60.207, -11.119, 'c'], [60.103, -10.94], [59.505, -9.912, 'c'], [58.321, -9.474, 'c'], [57.611, -8.591]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[2.2, -58], [2.2, -58, 'c'], [-7.038, -60.872, 'c'], [-18.2, -35.2], [-18.2, -35.2, 'c'], [-20.6, -30, 'c'], [-23, -28], [-25.4, -26, 'c'], [-36.6, -22.4, 'c'], [-38.6, -18.4], [-49, -2.4], [-49, -2.4, 'c'], [-34.2, -18.4, 'c'], [-31, -20.8], [-31, -20.8, 'c'], [-23, -29.2, 'c'], [-26.2, -22.4], [-26.2, -22.4, 'c'], [-40.2, -11.6, 'c'], [-39, -2.4], [-39, -2.4, 'c'], [-44.6, 12, 'c'], [-45.4, 14], [-45.4, 14, 'c'], [-29.4, -18, 'c'], [-27, -19.2], [-24.6, -20.4, 'c'], [-23.4, -20.4, 'c'], [-24.6, -16.8], [-25.8, -13.2, 'c'], [-26.2, 3.2, 'c'], [-29, 5.2], [-29, 5.2, 'c'], [-21, -15.2, 'c'], [-21.8, -18.4], [-21.8, -18.4, 'c'], [-18.6, -22, 'c'], [-16.2, -16.8], [-17.4, -0.8], [-13, 11.2], [-13, 11.2, 'c'], [-15.4, 0, 'c'], [-13.8, -15.6], [-13.8, -15.6, 'c'], [-15.8, -26, 'c'], [-11.8, -20.4], [-7.8, -14.8, 'c'], [1.8, -8.8, 'c'], [1.8, -4], [1.8, -4, 'c'], [-3.4, -21.6, 'c'], [-12.6, -26.4], [-16.6, -20.4], [-17.8, -22.4], [-17.8, -22.4, 'c'], [-21.4, -23.2, 'c'], [-17, -30], [-12.6, -36.8, 'c'], [-13, -37.6, 'c'], [-13, -37.6], [-13, -37.6, 'c'], [-6.6, -30.4, 'c'], [-5, -30.4], [-5, -30.4, 'c'], [8.2, -38, 'c'], [9.4, -13.6], [9.4, -13.6, 'c'], [16.2, -28, 'c'], [7, -34.8], [7, -34.8, 'c'], [-7.8, -36.8, 'c'], [-6.6, -42], [0.6, -54.4], [4.2, -59.6, 'c'], [2.6, -56.8, 'c'], [2.6, -56.8]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-17.8, -41.6], [-17.8, -41.6, 'c'], [-30.6, -41.6, 'c'], [-33.8, -36.4], [-41, -26.8], [-41, -26.8, 'c'], [-23.8, -36.8, 'c'], [-19.8, -38], [-15.8, -39.2, 'c'], [-17.8, -41.6, 'c'], [-17.8, -41.6]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-57.8, -35.2], [-57.8, -35.2, 'c'], [-59.8, -34, 'c'], [-60.2, -31.2], [-60.6, -28.4, 'c'], [-63, -28, 'c'], [-62.2, -25.2], [-61.4, -22.4, 'c'], [-59.4, -20, 'c'], [-59.4, -24], [-59.4, -28, 'c'], [-57.8, -30, 'c'], [-57, -31.2], [-56.2, -32.4, 'c'], [-54.6, -36.8, 'c'], [-57.8, -35.2]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-66.6, 26], [-66.6, 26, 'c'], [-75, 22, 'c'], [-78.2, 18.4], [-81.4, 14.8, 'c'], [-80.948, 19.966, 'c'], [-85.8, 19.6], [-91.647, 19.159, 'c'], [-90.6, 3.2, 'c'], [-90.6, 3.2], [-94.6, 10.8], [-94.6, 10.8, 'c'], [-95.8, 25.2, 'c'], [-87.8, 22.8], [-83.893, 21.628, 'c'], [-82.6, 23.2, 'c'], [-84.2, 24], [-85.8, 24.8, 'c'], [-78.6, 25.2, 'c'], [-81.4, 26.8], [-84.2, 28.4, 'c'], [-69.8, 23.2, 'c'], [-72.2, 33.6], [-66.6, 26]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-79.2, 40.4], [-79.2, 40.4, 'c'], [-94.6, 44.8, 'c'], [-98.2, 35.2], [-98.2, 35.2, 'c'], [-103, 37.6, 'c'], [-100.8, 40.6], [-98.6, 43.6, 'c'], [-97.4, 44, 'c'], [-97.4, 44], [-97.4, 44, 'c'], [-92, 45.2, 'c'], [-92.6, 46], [-93.2, 46.8, 'c'], [-95.6, 50.2, 'c'], [-95.6, 50.2], [-95.6, 50.2, 'c'], [-85.4, 44.2, 'c'], [-79.2, 40.4]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[149.201, 118.601], [148.774, 120.735, 'c'], [147.103, 121.536, 'c'], [145.201, 122.201], [143.284, 121.243, 'c'], [140.686, 118.137, 'c'], [138.801, 120.201], [138.327, 119.721, 'c'], [137.548, 119.661, 'c'], [137.204, 118.999], [136.739, 118.101, 'c'], [137.011, 117.055, 'c'], [136.669, 116.257], [136.124, 114.985, 'c'], [135.415, 113.619, 'c'], [135.601, 112.201], [137.407, 111.489, 'c'], [138.002, 109.583, 'c'], [137.528, 107.82], [137.459, 107.563, 'c'], [137.03, 107.366, 'c'], [137.23, 107.017], [137.416, 106.694, 'c'], [137.734, 106.467, 'c'], [138.001, 106.2], [137.866, 106.335, 'c'], [137.721, 106.568, 'c'], [137.61, 106.548], [137, 106.442, 'c'], [137.124, 105.805, 'c'], [137.254, 105.418], [137.839, 103.672, 'c'], [139.853, 103.408, 'c'], [141.201, 104.6], [141.457, 104.035, 'c'], [141.966, 104.229, 'c'], [142.401, 104.2], [142.351, 103.621, 'c'], [142.759, 103.094, 'c'], [142.957, 102.674], [143.475, 101.576, 'c'], [145.104, 102.682, 'c'], [145.901, 102.07], [146.977, 101.245, 'c'], [148.04, 100.546, 'c'], [149.118, 101.149], [150.927, 102.162, 'c'], [152.636, 103.374, 'c'], [153.835, 105.115], [154.41, 105.949, 'c'], [154.65, 107.23, 'c'], [154.592, 108.188], [154.554, 108.835, 'c'], [153.173, 108.483, 'c'], [152.83, 109.412], [152.185, 111.16, 'c'], [154.016, 111.679, 'c'], [154.772, 113.017], [154.97, 113.366, 'c'], [154.706, 113.67, 'c'], [154.391, 113.768], [153.98, 113.896, 'c'], [153.196, 113.707, 'c'], [153.334, 114.16], [154.306, 117.353, 'c'], [151.55, 118.031, 'c'], [149.201, 118.601]], -closed => 1, -fillcolor => "#ffffff", -filled => 1, -linecolor => "#ffffff");
-
-$zinc->add('curve',$top_group,[[139.6, 138.201], [139.593, 136.463, 'c'], [137.992, 134.707, 'c'], [139.201, 133.001], [139.336, 133.135, 'c'], [139.467, 133.356, 'c'], [139.601, 133.356], [139.736, 133.356, 'c'], [139.867, 133.135, 'c'], [140.001, 133.001], [141.496, 135.217, 'c'], [145.148, 136.145, 'c'], [145.006, 138.991], [144.984, 139.438, 'c'], [143.897, 140.356, 'c'], [144.801, 141.001], [142.988, 142.349, 'c'], [142.933, 144.719, 'c'], [142.001, 146.601], [140.763, 146.315, 'c'], [139.551, 145.952, 'c'], [138.401, 145.401], [138.753, 143.915, 'c'], [138.636, 142.231, 'c'], [139.456, 140.911], [139.89, 140.213, 'c'], [139.603, 139.134, 'c'], [139.6, 138.201]], -closed => 1, -fillcolor => "#ffffff", -filled => 1, -linecolor => "#ffffff");
-
-$zinc->add('curve',$top_group,[[-26.6, 129.201], [-26.6, 129.201, 'c'], [-43.458, 139.337, 'c'], [-29.4, 124.001], [-20.6, 114.401, 'c'], [-10.6, 108.801, 'c'], [-10.6, 108.801], [-10.6, 108.801, 'c'], [-0.2, 104.4, 'c'], [3.4, 103.2], [7, 102, 'c'], [22.2, 96.8, 'c'], [25.4, 96.4], [28.6, 96, 'c'], [38.2, 92, 'c'], [45, 96], [51.8, 100, 'c'], [59.8, 104.4, 'c'], [59.8, 104.4], [59.8, 104.4, 'c'], [43.4, 96, 'c'], [39.8, 98.4], [36.2, 100.8, 'c'], [29, 100.4, 'c'], [23, 103.6], [23, 103.6, 'c'], [8.2, 108.001, 'c'], [5, 110.001], [1.8, 112.001, 'c'], [-8.6, 123.601, 'c'], [-10.2, 122.801], [-11.8, 122.001, 'c'], [-9.8, 121.601, 'c'], [-8.6, 118.801], [-7.4, 116.001, 'c'], [-9.4, 114.401, 'c'], [-17.4, 120.801], [-25.4, 127.201, 'c'], [-26.6, 129.201, 'c'], [-26.6, 129.201]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[-19.195, 123.234], [-19.195, 123.234, 'c'], [-17.785, 110.194, 'c'], [-9.307, 111.859], [-9.307, 111.859, 'c'], [-1.081, 107.689, 'c'], [1.641, 105.721], [1.641, 105.721, 'c'], [9.78, 104.019, 'c'], [11.09, 103.402], [29.569, 94.702, 'c'], [44.288, 99.221, 'c'], [44.835, 98.101], [45.381, 96.982, 'c'], [65.006, 104.099, 'c'], [68.615, 108.185], [69.006, 108.628, 'c'], [58.384, 102.588, 'c'], [48.686, 100.697], [40.413, 99.083, 'c'], [18.811, 100.944, 'c'], [7.905, 106.48], [4.932, 107.989, 'c'], [-4.013, 113.773, 'c'], [-6.544, 113.662], [-9.075, 113.55, 'c'], [-19.195, 123.234, 'c'], [-19.195, 123.234]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-23, 148.801], [-23, 148.801, 'c'], [-38.2, 146.401, 'c'], [-21.4, 144.801], [-21.4, 144.801, 'c'], [-3.4, 142.801, 'c'], [0.6, 137.601], [0.6, 137.601, 'c'], [14.2, 128.401, 'c'], [17, 128.001], [19.8, 127.601, 'c'], [49.8, 120.401, 'c'], [50.2, 118.001], [50.6, 115.601, 'c'], [56.2, 115.601, 'c'], [57.8, 116.401], [59.4, 117.201, 'c'], [58.6, 118.401, 'c'], [55.8, 119.201], [53, 120.001, 'c'], [21.8, 136.401, 'c'], [15.4, 137.601], [9, 138.801, 'c'], [-2.6, 146.401, 'c'], [-7.4, 147.601], [-12.2, 148.801, 'c'], [-23, 148.801, 'c'], [-23, 148.801]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[-3.48, 141.403], [-3.48, 141.403, 'c'], [-12.062, 140.574, 'c'], [-3.461, 139.755], [-3.461, 139.755, 'c'], [5.355, 136.331, 'c'], [7.403, 133.668], [7.403, 133.668, 'c'], [14.367, 128.957, 'c'], [15.8, 128.753], [17.234, 128.548, 'c'], [31.194, 124.861, 'c'], [31.399, 123.633], [31.604, 122.404, 'c'], [65.67, 109.823, 'c'], [70.09, 113.013], [73.001, 115.114, 'c'], [63.1, 113.437, 'c'], [53.466, 117.847], [52.111, 118.467, 'c'], [18.258, 133.054, 'c'], [14.981, 133.668], [11.704, 134.283, 'c'], [5.765, 138.174, 'c'], [3.307, 138.788], [0.85, 139.403, 'c'], [-3.48, 141.403, 'c'], [-3.48, 141.403]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-11.4, 143.601], [-11.4, 143.601, 'c'], [-6.2, 143.201, 'c'], [-7.4, 144.801], [-8.6, 146.401, 'c'], [-11, 145.601, 'c'], [-11, 145.601], [-11.4, 143.601]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-18.6, 145.201], [-18.6, 145.201, 'c'], [-13.4, 144.801, 'c'], [-14.6, 146.401], [-15.8, 148.001, 'c'], [-18.2, 147.201, 'c'], [-18.2, 147.201], [-18.6, 145.201]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-29, 146.801], [-29, 146.801, 'c'], [-23.8, 146.401, 'c'], [-25, 148.001], [-26.2, 149.601, 'c'], [-28.6, 148.801, 'c'], [-28.6, 148.801], [-29, 146.801]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-36.6, 147.601], [-36.6, 147.601, 'c'], [-31.4, 147.201, 'c'], [-32.6, 148.801], [-33.8, 150.401, 'c'], [-36.2, 149.601, 'c'], [-36.2, 149.601], [-36.6, 147.601]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[1.8, 108.001], [1.8, 108.001, 'c'], [6.2, 108.001, 'c'], [5, 109.601], [3.8, 111.201, 'c'], [0.6, 110.801, 'c'], [0.6, 110.801], [1.8, 108.001]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-8.2, 113.601], [-8.2, 113.601, 'c'], [-1.694, 111.46, 'c'], [-4.2, 114.801], [-5.4, 116.401, 'c'], [-7.8, 115.601, 'c'], [-7.8, 115.601], [-8.2, 113.601]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-19.4, 118.401], [-19.4, 118.401, 'c'], [-14.2, 118.001, 'c'], [-15.4, 119.601], [-16.6, 121.201, 'c'], [-19, 120.401, 'c'], [-19, 120.401], [-19.4, 118.401]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-27, 124.401], [-27, 124.401, 'c'], [-21.8, 124.001, 'c'], [-23, 125.601], [-24.2, 127.201, 'c'], [-26.6, 126.401, 'c'], [-26.6, 126.401], [-27, 124.401]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-33.8, 129.201], [-33.8, 129.201, 'c'], [-28.6, 128.801, 'c'], [-29.8, 130.401], [-31, 132.001, 'c'], [-33.4, 131.201, 'c'], [-33.4, 131.201], [-33.8, 129.201]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[5.282, 135.598], [5.282, 135.598, 'c'], [12.203, 135.066, 'c'], [10.606, 137.195], [9.009, 139.325, 'c'], [5.814, 138.26, 'c'], [5.814, 138.26], [5.282, 135.598]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[15.682, 130.798], [15.682, 130.798, 'c'], [22.603, 130.266, 'c'], [21.006, 132.395], [19.409, 134.525, 'c'], [16.214, 133.46, 'c'], [16.214, 133.46], [15.682, 130.798]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[26.482, 126.398], [26.482, 126.398, 'c'], [33.403, 125.866, 'c'], [31.806, 127.995], [30.209, 130.125, 'c'], [27.014, 129.06, 'c'], [27.014, 129.06], [26.482, 126.398]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[36.882, 121.598], [36.882, 121.598, 'c'], [43.803, 121.066, 'c'], [42.206, 123.195], [40.609, 125.325, 'c'], [37.414, 124.26, 'c'], [37.414, 124.26], [36.882, 121.598]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[9.282, 103.598], [9.282, 103.598, 'c'], [16.203, 103.066, 'c'], [14.606, 105.195], [13.009, 107.325, 'c'], [9.014, 107.06, 'c'], [9.014, 107.06], [9.282, 103.598]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[19.282, 100.398], [19.282, 100.398, 'c'], [26.203, 99.866, 'c'], [24.606, 101.995], [23.009, 104.125, 'c'], [18.614, 103.86, 'c'], [18.614, 103.86], [19.282, 100.398]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-3.4, 140.401], [-3.4, 140.401, 'c'], [1.8, 140.001, 'c'], [0.6, 141.601], [-0.6, 143.201, 'c'], [-3, 142.401, 'c'], [-3, 142.401], [-3.4, 140.401]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-76.6, 41.2], [-76.6, 41.2, 'c'], [-81, 50, 'c'], [-81.4, 53.2], [-81.4, 53.2, 'c'], [-80.6, 44.4, 'c'], [-79.4, 42.4], [-78.2, 40.4, 'c'], [-76.6, 41.2, 'c'], [-76.6, 41.2]], -closed => 1, -fillcolor => "#992600", -filled => 1, -linecolor => "#992600");
-
-$zinc->add('curve',$top_group,[[-95, 55.2], [-95, 55.2, 'c'], [-98.2, 69.6, 'c'], [-97.8, 72.4], [-97.8, 72.4, 'c'], [-99, 60.8, 'c'], [-98.6, 59.6], [-98.2, 58.4, 'c'], [-95, 55.2, 'c'], [-95, 55.2]], -closed => 1, -fillcolor => "#992600", -filled => 1, -linecolor => "#992600");
-
-$zinc->add('curve',$top_group,[[-74.2, -19.4], [-74.4, -16.2], [-76.6, -16], [-76.6, -16, 'c'], [-62.4, -3.4, 'c'], [-61.8, 4.2], [-61.8, 4.2, 'c'], [-61, -4, 'c'], [-74.2, -19.4]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[-70.216, -18.135], [-70.647, -18.551, 'c'], [-70.428, -19.296, 'c'], [-70.836, -19.556], [-71.645, -20.072, 'c'], [-69.538, -20.129, 'c'], [-69.766, -20.845], [-70.149, -22.051, 'c'], [-69.962, -22.072, 'c'], [-70.084, -23.348], [-70.141, -23.946, 'c'], [-69.553, -25.486, 'c'], [-69.168, -25.926], [-67.722, -27.578, 'c'], [-69.046, -30.51, 'c'], [-67.406, -32.061], [-67.102, -32.35, 'c'], [-66.726, -32.902, 'c'], [-66.441, -33.32], [-65.782, -34.283, 'c'], [-64.598, -34.771, 'c'], [-63.648, -35.599], [-63.33, -35.875, 'c'], [-63.531, -36.702, 'c'], [-62.962, -36.61], [-62.248, -36.495, 'c'], [-61.007, -36.625, 'c'], [-61.052, -35.784], [-61.165, -33.664, 'c'], [-62.494, -31.944, 'c'], [-63.774, -30.276], [-63.323, -29.572, 'c'], [-63.781, -28.937, 'c'], [-64.065, -28.38], [-65.4, -25.76, 'c'], [-65.211, -22.919, 'c'], [-65.385, -20.079], [-65.39, -19.994, 'c'], [-65.697, -19.916, 'c'], [-65.689, -19.863], [-65.336, -17.528, 'c'], [-64.752, -15.329, 'c'], [-63.873, -13.1], [-63.507, -12.17, 'c'], [-63.036, -11.275, 'c'], [-62.886, -10.348], [-62.775, -9.662, 'c'], [-62.672, -8.829, 'c'], [-63.08, -8.124], [-61.045, -5.234, 'c'], [-62.354, -2.583, 'c'], [-61.185, 0.948], [-60.978, 1.573, 'c'], [-59.286, 3.487, 'c'], [-59.749, 3.326], [-62.262, 2.455, 'c'], [-62.374, 2.057, 'c'], [-62.551, 1.304], [-62.697, 0.681, 'c'], [-63.027, -0.696, 'c'], [-63.264, -1.298], [-63.328, -1.462, 'c'], [-63.499, -3.346, 'c'], [-63.577, -3.468], [-65.09, -5.85, 'c'], [-63.732, -5.674, 'c'], [-65.102, -8.032], [-66.53, -8.712, 'c'], [-67.496, -9.816, 'c'], [-68.619, -10.978], [-68.817, -11.182, 'c'], [-67.674, -11.906, 'c'], [-67.855, -12.119], [-68.947, -13.408, 'c'], [-70.1, -14.175, 'c'], [-69.764, -15.668], [-69.609, -16.358, 'c'], [-69.472, -17.415, 'c'], [-70.216, -18.135]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-73.8, -16.4], [-73.8, -16.4, 'c'], [-73.4, -9.6, 'c'], [-71, -8], [-68.6, -6.4, 'c'], [-69.8, -7.2, 'c'], [-73, -8.4], [-76.2, -9.6, 'c'], [-75, -10.4, 'c'], [-75, -10.4], [-75, -10.4, 'c'], [-77.8, -10, 'c'], [-75.4, -8], [-73, -6, 'c'], [-69.4, -3.6, 'c'], [-71, -3.6], [-72.6, -3.6, 'c'], [-80.2, -7.6, 'c'], [-80.2, -10.4], [-80.2, -13.2, 'c'], [-81.2, -17.3, 'c'], [-81.2, -17.3], [-81.2, -17.3, 'c'], [-80.1, -18.1, 'c'], [-75.3, -18], [-75.3, -18, 'c'], [-73.9, -17.3, 'c'], [-73.8, -16.4]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-74.6, 2.2], [-74.6, 2.2, 'c'], [-83.12, -0.591, 'c'], [-101.6, 2.8], [-101.6, 2.8, 'c'], [-92.569, 0.722, 'c'], [-73.8, 3], [-63.5, 4.25, 'c'], [-74.6, 2.2, 'c'], [-74.6, 2.2]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[-72.502, 2.129], [-72.502, 2.129, 'c'], [-80.748, -1.389, 'c'], [-99.453, 0.392], [-99.453, 0.392, 'c'], [-90.275, -0.897, 'c'], [-71.774, 2.995], [-61.62, 5.131, 'c'], [-72.502, 2.129, 'c'], [-72.502, 2.129]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[-70.714, 2.222], [-70.714, 2.222, 'c'], [-78.676, -1.899, 'c'], [-97.461, -1.514], [-97.461, -1.514, 'c'], [-88.213, -2.118, 'c'], [-70.052, 3.14], [-60.086, 6.025, 'c'], [-70.714, 2.222, 'c'], [-70.714, 2.222]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[-69.444, 2.445], [-69.444, 2.445, 'c'], [-76.268, -1.862, 'c'], [-93.142, -2.96], [-93.142, -2.96, 'c'], [-84.803, -2.79, 'c'], [-68.922, 3.319], [-60.206, 6.672, 'c'], [-69.444, 2.445, 'c'], [-69.444, 2.445]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[45.84, 12.961], [45.84, 12.961, 'c'], [44.91, 13.605, 'c'], [45.124, 12.424], [45.339, 11.243, 'c'], [73.547, -1.927, 'c'], [77.161, -1.677], [77.161, -1.677, 'c'], [46.913, 11.529, 'c'], [45.84, 12.961]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[42.446, 13.6], [42.446, 13.6, 'c'], [41.57, 14.315, 'c'], [41.691, 13.121], [41.812, 11.927, 'c'], [68.899, -3.418, 'c'], [72.521, -3.452], [72.521, -3.452, 'c'], [43.404, 12.089, 'c'], [42.446, 13.6]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[39.16, 14.975], [39.16, 14.975, 'c'], [38.332, 15.747, 'c'], [38.374, 14.547], [38.416, 13.348, 'c'], [58.233, -2.149, 'c'], [68.045, -4.023], [68.045, -4.023, 'c'], [50.015, 4.104, 'c'], [39.16, 14.975]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[36.284, 16.838], [36.284, 16.838, 'c'], [35.539, 17.532, 'c'], [35.577, 16.453], [35.615, 15.373, 'c'], [53.449, 1.426, 'c'], [62.28, -0.26], [62.28, -0.26, 'c'], [46.054, 7.054, 'c'], [36.284, 16.838]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[4.6, 164.801], [4.6, 164.801, 'c'], [-10.6, 162.401, 'c'], [6.2, 160.801], [6.2, 160.801, 'c'], [24.2, 158.801, 'c'], [28.2, 153.601], [28.2, 153.601, 'c'], [41.8, 144.401, 'c'], [44.6, 144.001], [47.4, 143.601, 'c'], [63.8, 140.001, 'c'], [64.2, 137.601], [64.6, 135.201, 'c'], [70.6, 132.801, 'c'], [72.2, 133.601], [73.8, 134.401, 'c'], [73.8, 143.601, 'c'], [71, 144.401], [68.2, 145.201, 'c'], [49.4, 152.401, 'c'], [43, 153.601], [36.6, 154.801, 'c'], [25, 162.401, 'c'], [20.2, 163.601], [15.4, 164.801, 'c'], [4.6, 164.801, 'c'], [4.6, 164.801]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[77.6, 127.401], [77.6, 127.401, 'c'], [74.6, 129.001, 'c'], [73.4, 131.601], [73.4, 131.601, 'c'], [67, 142.201, 'c'], [52.8, 145.401], [52.8, 145.401, 'c'], [29.8, 154.401, 'c'], [22, 156.401], [22, 156.401, 'c'], [8.6, 161.401, 'c'], [1.2, 160.601], [1.2, 160.601, 'c'], [-5.8, 160.801, 'c'], [0.4, 162.401], [0.4, 162.401, 'c'], [20.6, 160.401, 'c'], [24, 158.601], [24, 158.601, 'c'], [39.6, 153.401, 'c'], [42.6, 150.801], [45.6, 148.201, 'c'], [63.8, 143.201, 'c'], [66, 141.201], [68.2, 139.201, 'c'], [78, 130.801, 'c'], [77.6, 127.401]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[18.882, 158.911], [18.882, 158.911, 'c'], [24.111, 158.685, 'c'], [22.958, 160.234], [21.805, 161.784, 'c'], [19.357, 160.91, 'c'], [19.357, 160.91], [18.882, 158.911]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[11.68, 160.263], [11.68, 160.263, 'c'], [16.908, 160.037, 'c'], [15.756, 161.586], [14.603, 163.136, 'c'], [12.155, 162.263, 'c'], [12.155, 162.263], [11.68, 160.263]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[1.251, 161.511], [1.251, 161.511, 'c'], [6.48, 161.284, 'c'], [5.327, 162.834], [4.174, 164.383, 'c'], [1.726, 163.51, 'c'], [1.726, 163.51], [1.251, 161.511]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-6.383, 162.055], [-6.383, 162.055, 'c'], [-1.154, 161.829, 'c'], [-2.307, 163.378], [-3.46, 164.928, 'c'], [-5.908, 164.054, 'c'], [-5.908, 164.054], [-6.383, 162.055]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[35.415, 151.513], [35.415, 151.513, 'c'], [42.375, 151.212, 'c'], [40.84, 153.274], [39.306, 155.336, 'c'], [36.047, 154.174, 'c'], [36.047, 154.174], [35.415, 151.513]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[45.73, 147.088], [45.73, 147.088, 'c'], [51.689, 143.787, 'c'], [51.155, 148.849], [50.885, 151.405, 'c'], [46.362, 149.749, 'c'], [46.362, 149.749], [45.73, 147.088]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[54.862, 144.274], [54.862, 144.274, 'c'], [62.021, 140.573, 'c'], [60.287, 146.035], [59.509, 148.485, 'c'], [55.493, 146.935, 'c'], [55.493, 146.935], [54.862, 144.274]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[64.376, 139.449], [64.376, 139.449, 'c'], [68.735, 134.548, 'c'], [69.801, 141.21], [70.207, 143.748, 'c'], [65.008, 142.11, 'c'], [65.008, 142.11], [64.376, 139.449]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[26.834, 155.997], [26.834, 155.997, 'c'], [32.062, 155.77, 'c'], [30.91, 157.32], [29.757, 158.869, 'c'], [27.308, 157.996, 'c'], [27.308, 157.996], [26.834, 155.997]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[62.434, 34.603], [62.434, 34.603, 'c'], [61.708, 35.268, 'c'], [61.707, 34.197], [61.707, 33.127, 'c'], [79.191, 19.863, 'c'], [88.034, 18.479], [88.034, 18.479, 'c'], [71.935, 25.208, 'c'], [62.434, 34.603]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[65.4, 98.4], [65.4, 98.4, 'c'], [87.401, 120.801, 'c'], [96.601, 124.401], [96.601, 124.401, 'c'], [105.801, 135.601, 'c'], [101.801, 161.601], [101.801, 161.601, 'c'], [98.601, 169.201, 'c'], [95.401, 148.401], [95.401, 148.401, 'c'], [98.601, 123.201, 'c'], [87.401, 139.201], [87.401, 139.201, 'c'], [79, 129.301, 'c'], [85.4, 129.601], [85.4, 129.601, 'c'], [88.601, 131.601, 'c'], [89.001, 130.001], [89.401, 128.401, 'c'], [81.4, 114.801, 'c'], [64.2, 100.4], [47, 86, 'c'], [65.4, 98.4, 'c'], [65.4, 98.4]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[7, 137.201], [7, 137.201, 'c'], [6.8, 135.401, 'c'], [8.6, 136.201], [10.4, 137.001, 'c'], [104.601, 143.201, 'c'], [136.201, 167.201], [136.201, 167.201, 'c'], [91.001, 144.001, 'c'], [7, 137.201]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[17.4, 132.801], [17.4, 132.801, 'c'], [17.2, 131.001, 'c'], [19, 131.801], [20.8, 132.601, 'c'], [157.401, 131.601, 'c'], [181.001, 164.001], [181.001, 164.001, 'c'], [159.001, 138.801, 'c'], [17.4, 132.801]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[29, 128.801], [29, 128.801, 'c'], [28.8, 127.001, 'c'], [30.6, 127.801], [32.4, 128.601, 'c'], [205.801, 115.601, 'c'], [229.401, 148.001], [229.401, 148.001, 'c'], [219.801, 122.401, 'c'], [29, 128.801]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[39, 124.001], [39, 124.001, 'c'], [38.8, 122.201, 'c'], [40.6, 123.001], [42.4, 123.801, 'c'], [164.601, 85.2, 'c'], [188.201, 117.601], [188.201, 117.601, 'c'], [174.801, 93, 'c'], [39, 124.001]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[-19, 146.801], [-19, 146.801, 'c'], [-19.2, 145.001, 'c'], [-17.4, 145.801], [-15.6, 146.601, 'c'], [2.2, 148.801, 'c'], [4.2, 187.601], [4.2, 187.601, 'c'], [-3, 145.601, 'c'], [-19, 146.801]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[-27.8, 148.401], [-27.8, 148.401, 'c'], [-28, 146.601, 'c'], [-26.2, 147.401], [-24.4, 148.201, 'c'], [-10.2, 143.601, 'c'], [-13, 182.401], [-13, 182.401, 'c'], [-11.8, 147.201, 'c'], [-27.8, 148.401]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[-35.8, 148.801], [-35.8, 148.801, 'c'], [-36, 147.001, 'c'], [-34.2, 147.801], [-32.4, 148.601, 'c'], [-17, 149.201, 'c'], [-29.4, 171.601], [-29.4, 171.601, 'c'], [-19.8, 147.601, 'c'], [-35.8, 148.801]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[11.526, 104.465], [11.526, 104.465, 'c'], [11.082, 106.464, 'c'], [12.631, 105.247], [28.699, 92.622, 'c'], [61.141, 33.72, 'c'], [116.826, 28.086], [116.826, 28.086, 'c'], [78.518, 15.976, 'c'], [11.526, 104.465]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[22.726, 102.665], [22.726, 102.665, 'c'], [21.363, 101.472, 'c'], [23.231, 100.847], [25.099, 100.222, 'c'], [137.541, 27.72, 'c'], [176.826, 35.686], [176.826, 35.686, 'c'], [149.719, 28.176, 'c'], [22.726, 102.665]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[1.885, 108.767], [1.885, 108.767, 'c'], [1.376, 110.366, 'c'], [3.087, 109.39], [12.062, 104.27, 'c'], [15.677, 47.059, 'c'], [59.254, 45.804], [59.254, 45.804, 'c'], [26.843, 31.09, 'c'], [1.885, 108.767]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[-18.038, 119.793], [-18.038, 119.793, 'c'], [-19.115, 121.079, 'c'], [-17.162, 120.825], [-6.916, 119.493, 'c'], [14.489, 78.222, 'c'], [58.928, 83.301], [58.928, 83.301, 'c'], [26.962, 68.955, 'c'], [-18.038, 119.793]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[-6.8, 113.667], [-6.8, 113.667, 'c'], [-7.611, 115.136, 'c'], [-5.742, 114.511], [4.057, 111.237, 'c'], [17.141, 66.625, 'c'], [61.729, 63.078], [61.729, 63.078, 'c'], [27.603, 55.135, 'c'], [-6.8, 113.667]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[-25.078, 124.912], [-25.078, 124.912, 'c'], [-25.951, 125.954, 'c'], [-24.369, 125.748], [-16.07, 124.669, 'c'], [1.268, 91.24, 'c'], [37.264, 95.354], [37.264, 95.354, 'c'], [11.371, 83.734, 'c'], [-25.078, 124.912]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[-32.677, 130.821], [-32.677, 130.821, 'c'], [-33.682, 131.866, 'c'], [-32.091, 131.748], [-27.923, 131.439, 'c'], [2.715, 98.36, 'c'], [21.183, 113.862], [21.183, 113.862, 'c'], [9.168, 95.139, 'c'], [-32.677, 130.821]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[36.855, 98.898], [36.855, 98.898, 'c'], [35.654, 97.543, 'c'], [37.586, 97.158], [39.518, 96.774, 'c'], [160.221, 39.061, 'c'], [198.184, 51.927], [198.184, 51.927, 'c'], [172.243, 41.053, 'c'], [36.855, 98.898]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[3.4, 163.201], [3.4, 163.201, 'c'], [3.2, 161.401, 'c'], [5, 162.201], [6.8, 163.001, 'c'], [22.2, 163.601, 'c'], [9.8, 186.001], [9.8, 186.001, 'c'], [19.4, 162.001, 'c'], [3.4, 163.201]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[13.8, 161.601], [13.8, 161.601, 'c'], [13.6, 159.801, 'c'], [15.4, 160.601], [17.2, 161.401, 'c'], [35, 163.601, 'c'], [37, 202.401], [37, 202.401, 'c'], [29.8, 160.401, 'c'], [13.8, 161.601]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[20.6, 160.001], [20.6, 160.001, 'c'], [20.4, 158.201, 'c'], [22.2, 159.001], [24, 159.801, 'c'], [48.6, 163.201, 'c'], [72.2, 195.601], [72.2, 195.601, 'c'], [36.6, 158.801, 'c'], [20.6, 160.001]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[28.225, 157.972], [28.225, 157.972, 'c'], [27.788, 156.214, 'c'], [29.678, 156.768], [31.568, 157.322, 'c'], [52.002, 155.423, 'c'], [90.099, 189.599], [90.099, 189.599, 'c'], [43.924, 154.656, 'c'], [28.225, 157.972]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[38.625, 153.572], [38.625, 153.572, 'c'], [38.188, 151.814, 'c'], [40.078, 152.368], [41.968, 152.922, 'c'], [76.802, 157.423, 'c'], [128.499, 192.399], [128.499, 192.399, 'c'], [54.324, 150.256, 'c'], [38.625, 153.572]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[-1.8, 142.001], [-1.8, 142.001, 'c'], [-2, 140.201, 'c'], [-0.2, 141.001], [1.6, 141.801, 'c'], [55, 144.401, 'c'], [85.4, 171.201], [85.4, 171.201, 'c'], [50.499, 146.426, 'c'], [-1.8, 142.001]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[-11.8, 146.001], [-11.8, 146.001, 'c'], [-12, 144.201, 'c'], [-10.2, 145.001], [-8.4, 145.801, 'c'], [16.2, 149.201, 'c'], [39.8, 181.601], [39.8, 181.601, 'c'], [4.2, 144.801, 'c'], [-11.8, 146.001]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[49.503, 148.962], [49.503, 148.962, 'c'], [48.938, 147.241, 'c'], [50.864, 147.655], [52.79, 148.068, 'c'], [87.86, 150.004, 'c'], [141.981, 181.098], [141.981, 181.098, 'c'], [64.317, 146.704, 'c'], [49.503, 148.962]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[57.903, 146.562], [57.903, 146.562, 'c'], [57.338, 144.841, 'c'], [59.264, 145.255], [61.19, 145.668, 'c'], [96.26, 147.604, 'c'], [150.381, 178.698], [150.381, 178.698, 'c'], [73.317, 143.904, 'c'], [57.903, 146.562]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[67.503, 141.562], [67.503, 141.562, 'c'], [66.938, 139.841, 'c'], [68.864, 140.255], [70.79, 140.668, 'c'], [113.86, 145.004, 'c'], [203.582, 179.298], [203.582, 179.298, 'c'], [82.917, 138.904, 'c'], [67.503, 141.562]], -closed => 1, -linecolor => "#000000", -fillcolor => "#ffffff", -filled => 1, -linewidth => 0.1);
-
-$zinc->add('curve',$top_group,[[-43.8, 148.401], [-43.8, 148.401, 'c'], [-38.6, 148.001, 'c'], [-39.8, 149.601], [-41, 151.201, 'c'], [-43.4, 150.401, 'c'], [-43.4, 150.401], [-43.8, 148.401]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-13, 162.401], [-13, 162.401, 'c'], [-7.8, 162.001, 'c'], [-9, 163.601], [-10.2, 165.201, 'c'], [-12.6, 164.401, 'c'], [-12.6, 164.401], [-13, 162.401]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-21.8, 162.001], [-21.8, 162.001, 'c'], [-16.6, 161.601, 'c'], [-17.8, 163.201], [-19, 164.801, 'c'], [-21.4, 164.001, 'c'], [-21.4, 164.001], [-21.8, 162.001]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-117.169, 150.182], [-117.169, 150.182, 'c'], [-112.124, 151.505, 'c'], [-113.782, 152.624], [-115.439, 153.744, 'c'], [-117.446, 152.202, 'c'], [-117.446, 152.202], [-117.169, 150.182]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-115.169, 140.582], [-115.169, 140.582, 'c'], [-110.124, 141.905, 'c'], [-111.782, 143.024], [-113.439, 144.144, 'c'], [-115.446, 142.602, 'c'], [-115.446, 142.602], [-115.169, 140.582]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-122.369, 136.182], [-122.369, 136.182, 'c'], [-117.324, 137.505, 'c'], [-118.982, 138.624], [-120.639, 139.744, 'c'], [-122.646, 138.202, 'c'], [-122.646, 138.202], [-122.369, 136.182]], -closed => 1, -fillcolor => "#000000", -filled => 1, -linecolor => "#000000");
-
-$zinc->add('curve',$top_group,[[-42.6, 211.201], [-42.6, 211.201, 'c'], [-44.2, 211.201, 'c'], [-48.2, 213.201], [-50.2, 213.201, 'c'], [-61.4, 216.801, 'c'], [-67, 226.801], [-67, 226.801, 'c'], [-54.6, 217.201, 'c'], [-42.6, 211.201]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[45.116, 303.847], [45.257, 304.105, 'c'], [45.312, 304.525, 'c'], [45.604, 304.542], [46.262, 304.582, 'c'], [47.495, 304.883, 'c'], [47.37, 304.247], [46.522, 299.941, 'c'], [45.648, 295.004, 'c'], [41.515, 293.197], [40.876, 292.918, 'c'], [39.434, 293.331, 'c'], [39.36, 294.215], [39.233, 295.739, 'c'], [39.116, 297.088, 'c'], [39.425, 298.554], [39.725, 299.975, 'c'], [41.883, 299.985, 'c'], [42.8, 298.601], [43.736, 300.273, 'c'], [44.168, 302.116, 'c'], [45.116, 303.847]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[34.038, 308.581], [34.786, 309.994, 'c'], [34.659, 311.853, 'c'], [36.074, 312.416], [36.814, 312.71, 'c'], [38.664, 311.735, 'c'], [38.246, 310.661], [37.444, 308.6, 'c'], [37.056, 306.361, 'c'], [35.667, 304.55], [35.467, 304.288, 'c'], [35.707, 303.755, 'c'], [35.547, 303.427], [34.953, 302.207, 'c'], [33.808, 301.472, 'c'], [32.4, 301.801], [31.285, 304.004, 'c'], [32.433, 306.133, 'c'], [33.955, 307.842], [34.091, 307.994, 'c'], [33.925, 308.37, 'c'], [34.038, 308.581]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[-5.564, 303.391], [-5.672, 303.014, 'c'], [-5.71, 302.551, 'c'], [-5.545, 302.23], [-5.014, 301.197, 'c'], [-4.221, 300.075, 'c'], [-4.558, 299.053], [-4.906, 297.997, 'c'], [-6.022, 298.179, 'c'], [-6.672, 298.748], [-7.807, 299.742, 'c'], [-7.856, 301.568, 'c'], [-8.547, 302.927], [-8.743, 303.313, 'c'], [-8.692, 303.886, 'c'], [-9.133, 304.277], [-9.607, 304.698, 'c'], [-10.047, 306.222, 'c'], [-9.951, 306.793], [-9.898, 307.106, 'c'], [-10.081, 317.014, 'c'], [-9.859, 316.751], [-9.24, 316.018, 'c'], [-6.19, 306.284, 'c'], [-6.121, 305.392], [-6.064, 304.661, 'c'], [-5.332, 304.196, 'c'], [-5.564, 303.391]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[-31.202, 296.599], [-28.568, 294.1, 'c'], [-25.778, 291.139, 'c'], [-26.22, 287.427], [-26.336, 286.451, 'c'], [-28.111, 286.978, 'c'], [-28.298, 287.824], [-29.1, 291.449, 'c'], [-31.139, 294.11, 'c'], [-33.707, 296.502], [-35.903, 298.549, 'c'], [-37.765, 304.893, 'c'], [-38, 305.401], [-34.303, 300.145, 'c'], [-32.046, 297.399, 'c'], [-31.202, 296.599]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[-44.776, 290.635], [-44.253, 290.265, 'c'], [-44.555, 289.774, 'c'], [-44.338, 289.442], [-43.385, 287.984, 'c'], [-42.084, 286.738, 'c'], [-42.066, 285], [-42.063, 284.723, 'c'], [-42.441, 284.414, 'c'], [-42.776, 284.638], [-43.053, 284.822, 'c'], [-43.395, 284.952, 'c'], [-43.503, 285.082], [-45.533, 287.531, 'c'], [-46.933, 290.202, 'c'], [-48.376, 293.014], [-48.559, 293.371, 'c'], [-49.703, 297.862, 'c'], [-49.39, 297.973], [-49.151, 298.058, 'c'], [-47.431, 293.877, 'c'], [-47.221, 293.763], [-45.958, 293.077, 'c'], [-45.946, 291.462, 'c'], [-44.776, 290.635]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[-28.043, 310.179], [-27.599, 309.31, 'c'], [-26.023, 308.108, 'c'], [-26.136, 307.219], [-26.254, 306.291, 'c'], [-25.786, 304.848, 'c'], [-26.698, 305.536], [-27.955, 306.484, 'c'], [-31.404, 307.833, 'c'], [-31.674, 313.641], [-31.7, 314.212, 'c'], [-28.726, 311.519, 'c'], [-28.043, 310.179]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[-13.6, 293.001], [-13.2, 292.333, 'c'], [-12.492, 292.806, 'c'], [-12.033, 292.543], [-11.385, 292.171, 'c'], [-10.774, 291.613, 'c'], [-10.482, 290.964], [-9.512, 288.815, 'c'], [-7.743, 286.995, 'c'], [-7.6, 284.601], [-9.091, 283.196, 'c'], [-9.77, 285.236, 'c'], [-10.4, 286.201], [-11.723, 284.554, 'c'], [-12.722, 286.428, 'c'], [-14.022, 286.947], [-14.092, 286.975, 'c'], [-14.305, 286.628, 'c'], [-14.38, 286.655], [-15.557, 287.095, 'c'], [-16.237, 288.176, 'c'], [-17.235, 288.957], [-17.406, 289.091, 'c'], [-17.811, 288.911, 'c'], [-17.958, 289.047], [-18.61, 289.65, 'c'], [-19.583, 289.975, 'c'], [-19.863, 290.657], [-20.973, 293.364, 'c'], [-24.113, 295.459, 'c'], [-26, 303.001], [-25.619, 303.91, 'c'], [-21.488, 296.359, 'c'], [-21.001, 295.661], [-20.165, 294.465, 'c'], [-20.047, 297.322, 'c'], [-18.771, 296.656], [-18.72, 296.629, 'c'], [-18.534, 296.867, 'c'], [-18.4, 297.001], [-18.206, 296.721, 'c'], [-17.988, 296.492, 'c'], [-17.6, 296.601], [-17.6, 296.201, 'c'], [-17.734, 295.645, 'c'], [-17.533, 295.486], [-16.296, 294.509, 'c'], [-16.38, 293.441, 'c'], [-15.6, 292.201], [-15.142, 292.99, 'c'], [-14.081, 292.271, 'c'], [-13.6, 293.001]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[46.2, 347.401], [46.2, 347.401, 'c'], [53.6, 327.001, 'c'], [49.2, 315.801], [49.2, 315.801, 'c'], [60.6, 337.401, 'c'], [56, 348.601], [56, 348.601, 'c'], [55.6, 338.201, 'c'], [51.6, 333.201], [51.6, 333.201, 'c'], [47.6, 346.001, 'c'], [46.2, 347.401]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[31.4, 344.801], [31.4, 344.801, 'c'], [36.8, 336.001, 'c'], [28.8, 317.601], [28.8, 317.601, 'c'], [28, 338.001, 'c'], [21.2, 349.001], [21.2, 349.001, 'c'], [35.4, 328.801, 'c'], [31.4, 344.801]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[21.4, 342.801], [21.4, 342.801, 'c'], [21.2, 322.801, 'c'], [21.6, 319.801], [21.6, 319.801, 'c'], [17.8, 336.401, 'c'], [7.6, 346.001], [7.6, 346.001, 'c'], [22, 334.001, 'c'], [21.4, 342.801]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[11.8, 310.801], [11.8, 310.801, 'c'], [17.8, 324.401, 'c'], [7.8, 342.801], [7.8, 342.801, 'c'], [14.2, 330.601, 'c'], [9.4, 323.601], [9.4, 323.601, 'c'], [12, 320.201, 'c'], [11.8, 310.801]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[-7.4, 342.401], [-7.4, 342.401, 'c'], [-8.4, 326.801, 'c'], [-6.6, 324.601], [-6.6, 324.601, 'c'], [-6.4, 318.201, 'c'], [-6.8, 317.201], [-6.8, 317.201, 'c'], [-2.8, 311.001, 'c'], [-2.6, 318.401], [-2.6, 318.401, 'c'], [-1.2, 326.201, 'c'], [1.6, 330.801], [1.6, 330.801, 'c'], [5.2, 336.201, 'c'], [5, 342.601], [5, 342.601, 'c'], [-5, 312.401, 'c'], [-7.4, 342.401]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[-11, 314.801], [-11, 314.801, 'c'], [-17.6, 325.601, 'c'], [-19.4, 344.601], [-19.4, 344.601, 'c'], [-20.8, 338.401, 'c'], [-17, 324.001], [-17, 324.001, 'c'], [-12.8, 308.601, 'c'], [-11, 314.801]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[-32.8, 334.601], [-32.8, 334.601, 'c'], [-27.8, 329.201, 'c'], [-26.4, 324.201], [-26.4, 324.201, 'c'], [-22.8, 308.401, 'c'], [-29.2, 317.001], [-29.2, 317.001, 'c'], [-29, 325.001, 'c'], [-37.2, 332.401], [-37.2, 332.401, 'c'], [-32.4, 330.001, 'c'], [-32.8, 334.601]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[-38.6, 329.601], [-38.6, 329.601, 'c'], [-35.2, 312.201, 'c'], [-34.4, 311.401], [-34.4, 311.401, 'c'], [-32.6, 308.001, 'c'], [-35.4, 311.201], [-35.4, 311.201, 'c'], [-44.2, 330.401, 'c'], [-48.2, 337.001], [-48.2, 337.001, 'c'], [-40.2, 327.801, 'c'], [-38.6, 329.601]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[-44.4, 313.001], [-44.4, 313.001, 'c'], [-32.8, 290.601, 'c'], [-54.6, 316.401], [-54.6, 316.401, 'c'], [-43.6, 306.601, 'c'], [-44.4, 313.001]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[-59.8, 298.401], [-59.8, 298.401, 'c'], [-55, 279.601, 'c'], [-52.4, 279.801], [-52.4, 279.801, 'c'], [-44.2, 270.801, 'c'], [-50.8, 281.401], [-50.8, 281.401, 'c'], [-56.8, 291.001, 'c'], [-56.2, 300.801], [-56.2, 300.801, 'c'], [-56.8, 291.201, 'c'], [-59.8, 298.401]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[270.5, 287], [270.5, 287, 'c'], [258.5, 277, 'c'], [256, 273.5], [256, 273.5, 'c'], [269.5, 292, 'c'], [269.5, 299], [269.5, 299, 'c'], [272, 291.5, 'c'], [270.5, 287]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[276, 265], [276, 265, 'c'], [255, 250, 'c'], [251.5, 242.5], [251.5, 242.5, 'c'], [278, 272, 'c'], [278, 276.5], [278, 276.5, 'c'], [278.5, 267.5, 'c'], [276, 265]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[293, 111], [293, 111, 'c'], [281, 103, 'c'], [279.5, 105], [279.5, 105, 'c'], [290, 111.5, 'c'], [292.5, 120], [292.5, 120, 'c'], [291, 111, 'c'], [293, 111]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-$zinc->add('curve',$top_group,[[301.5, 191.5], [284, 179.5], [284, 179.5, 'c'], [303, 196.5, 'c'], [303.5, 200.5], [301.5, 191.5]], -closed => 1, -fillcolor => "#cccccc", -filled => 1, -linecolor => "#cccccc");
-
-
-
-### translating ojects for making them all visibles
-$zinc->translate($top_group, 200, 150);
-
-
-### on ajoute quelques binding bien pratiques pour la mise au point
-
-my $i=0;
-
-$zinc->Tk::bind('<ButtonPress-1>', [\&press, \&motion]);
-$zinc->Tk::bind('<ButtonRelease-1>', [\&release]);
-$zinc->Tk::bind('<ButtonPress-2>', [\&press, \&zoom]);
-$zinc->Tk::bind('<ButtonRelease-2>', [\&release]);
-$zinc->Tk::bind('<ButtonPress-3>', [\&press, \&rotate]);
-$zinc->Tk::bind('<ButtonRelease-3>', [\&release]);
-
-
-&Tk::MainLoop;
-
-
-##### bindings for moving, rotating, scaling the items
-my ($cur_x, $cur_y, $cur_angle);
-sub press {
- my ($zinc, $action) = @_;
- my $ev = $zinc->XEvent();
- $cur_x = $ev->x;
- $cur_y = $ev->y;
- $cur_angle = atan2($cur_y, $cur_x);
- $zinc->Tk::bind('<Motion>', [$action]);
-}
-
-sub motion {
- my ($zinc) = @_;
- my $ev = $zinc->XEvent();
- my $lx = $ev->x;
- my $ly = $ev->y;
- my @res = $zinc->transform($top_group, [$lx, $ly, $cur_x, $cur_y]);
- $zinc->translate($top_group, $res[0] - $res[2], $res[1] - $res[3]);
- $cur_x = $lx;
- $cur_y = $ly;
- $i++;
-}
-
-sub zoom {
- my ($zinc, $self) = @_;
- my $ev = $zinc->XEvent();
- my $lx = $ev->x;
- my $ly = $ev->y;
- my $maxx;
- my $maxy;
- my $sx;
- my $sy;
-
- if ($lx > $cur_x) {
- $maxx = $lx;
- } else {
- $maxx = $cur_x;
- }
- if ($ly > $cur_y) {
- $maxy = $ly
- } else {
- $maxy = $cur_y;
- }
- return if ($maxx == 0 || $maxy == 0);
- $sx = 1.0 + ($lx - $cur_x)/$maxx;
- $sy = 1.0 + ($ly - $cur_y)/$maxy;
- $cur_x = $lx;
- $cur_y = $ly;
- $zinc->scale($top_group, $sx, $sx); #$sy);
-}
-
-sub rotate {
- my ($zinc) = @_;
- my $ev = $zinc->XEvent();
- my $lx = $ev->x;
- my $ly = $ev->y;
- my $langle;
-
- $langle = atan2($ly, $lx);
- $zinc->rotate($top_group, -($langle - $cur_angle));
- $cur_angle = $langle;
-}
-
-sub release {
- my ($zinc) = @_;
- $zinc->Tk::bind('<Motion>', '');
-}
diff --git a/Perl/demos/Tk/demos/zinc_lib/tkZincLogo.pl b/Perl/demos/Tk/demos/zinc_lib/tkZincLogo.pl
deleted file mode 100644
index 8e3ca9d..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/tkZincLogo.pl
+++ /dev/null
@@ -1,165 +0,0 @@
-#!/usr/bin/perl
-# $Id$
-# this simple demo has been adapted by C. Mertz <mertz@cena.fr> from the original
-# work of JL. Vinot <vinot@cena.fr>
-
-package tkZincLogo; # for avoiding symbol collision between different demos
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-use Tk::Zinc;
-use strict;
-use Tk::Zinc::Logo; # this module implements a class which instances are Zinc logo!
-
-my $defaultfont = '-adobe-helvetica-bold-r-normal--*-140-*-*-*-*-*-*';
-my $mw = MainWindow->new();
-my $text = $mw->Scrolled(qw/Text -relief sunken -borderwidth 2 -setgrid true
- -height 7 -scrollbars ''/);
-$text->pack(qw/-expand yes -fill both/);
-
-$text->insert('0.0',
- 'This tkZinc logo should used openGL for a correct rendering!
- You can transform this logo with your mouse:
- Drag-Button 1 for moving the logo,
- Drag-Button 2 for zooming the logo,
- Drag-Button 3 for rotating the logo,
- Shift-Drag-Button 1 for modifying the logo transparency,
- Shift-Drag-Button 2 for modifying the logo gradient.'
- );
-
-my $zinc = $mw->Zinc(-width => 350, -height => 250,
- -render => 1,
- -font => "10x20", # usually fonts are sets in resources
- # but for this example it is set in the code!
- -borderwidth => 3, -relief => 'sunken',
- )->pack;
-
-my $group = $zinc->add('group', 1, );
-
-
-my $logo = Tk::Zinc::Logo->new(-widget => $zinc,
- -parent => $group,
- -position => [40, 70],
- -priority => 800,
- -scale => [.6, .6],
- );
-
-
-$zinc->Tk::bind('<ButtonPress-1>', [\&press, \&motion]);
-$zinc->Tk::bind('<ButtonRelease-1>', [\&release]);
-
-$zinc->Tk::bind('<ButtonPress-2>', [\&press, \&zoom]);
-$zinc->Tk::bind('<ButtonRelease-2>', [\&release]);
-
-$zinc->Tk::bind('<ButtonPress-3>', [\&press, \&rotate]);
-$zinc->Tk::bind('<ButtonRelease-3>', [\&release]);
-
-
-$zinc->Tk::bind('<Shift-ButtonPress-1>', [\&press, \&modifyAlpha]);
-$zinc->Tk::bind('<Shift-ButtonRelease-1>', [\&release]);
-
-$zinc->Tk::bind('<Shift-ButtonPress-2>', [\&press, \&modifyGradient]);
-$zinc->Tk::bind('<Shift-ButtonRelease-2>', [\&release]);
-
-
-#
-# Controls for the window transform.
-#
-my ($cur_x, $cur_y, $cur_angle);
-sub press {
- my ($zinc, $action) = @_;
- my $ev = $zinc->XEvent();
- $cur_x = $ev->x;
- $cur_y = $ev->y;
- $cur_angle = atan2($cur_y, $cur_x);
- $zinc->Tk::bind('<Motion>', [$action]);
-}
-
-sub modifyAlpha {
- my ($zinc) = @_;
- my $ev = $zinc->XEvent();
- my $lx = $ev->x;
- my $xrate = $lx / $zinc->cget(-width);
-
- $xrate = 0 if $xrate < 0;
- $xrate = 1 if $xrate > 1;
-
- my $alpha = $xrate * 100;
- $zinc->itemconfigure($group, -alpha => $alpha);
-}
-
-sub modifyGradient {
- my ($zinc) = @_;
- my $ev = $zinc->XEvent();
- my $ly = $ev->y;
- my $yrate = $ly / $zinc->cget(-height);
-
- $yrate = 0 if $yrate < 0;
- $yrate = 1 if $yrate > 1;
- my $gradientpercent = sprintf ("%d", $yrate * 100);
-
- $zinc->itemconfigure ('zinc_shape', -fillcolor => "=axial 270|#ffffff 0 28|#66848c $gradientpercent|#7192aa");
-}
-
-
-sub motion {
- my ($zinc) = @_;
- my $ev = $zinc->XEvent();
- my $lx = $ev->x;
- my $ly = $ev->y;
- my @res;
-
- @res = $zinc->transform($group, [$lx, $ly, $cur_x, $cur_y]);
- $zinc->translate($group, $res[0] - $res[2], $res[1] - $res[3]);
- $cur_x = $lx;
- $cur_y = $ly;
-}
-
-sub zoom {
- my ($zinc, $self) = @_;
- my $ev = $zinc->XEvent();
- my $lx = $ev->x;
- my $ly = $ev->y;
- my $maxx;
- my $maxy;
- my $sx;
- my $sy;
-
- if ($lx > $cur_x) {
- $maxx = $lx;
- } else {
- $maxx = $cur_x;
- }
- if ($ly > $cur_y) {
- $maxy = $ly
- } else {
- $maxy = $cur_y;
- }
- return if ($maxx == 0 || $maxy == 0);
- $sx = 1.0 + ($lx - $cur_x)/$maxx;
- $sy = 1.0 + ($ly - $cur_y)/$maxy;
- $cur_x = $lx;
- $cur_y = $ly;
- $zinc->scale($group, $sx, $sy);
-}
-
-sub rotate {
- my ($zinc) = @_;
- my $ev = $zinc->XEvent();
- my $lx = $ev->x;
- my $ly = $ev->y;
- my $langle;
-
- $langle = atan2($ly, $lx);
- $zinc->rotate($group, -($langle - $cur_angle));
- $cur_angle = $langle;
-}
-
-sub release {
- my ($zinc) = @_;
- $zinc->Tk::bind('<Motion>', '');
-}
-
-Tk::MainLoop;
diff --git a/Perl/demos/Tk/demos/zinc_lib/transforms.pl b/Perl/demos/Tk/demos/zinc_lib/transforms.pl
deleted file mode 100644
index 0d8cab0..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/transforms.pl
+++ /dev/null
@@ -1,568 +0,0 @@
-#!/usr/bin/perl -w
-
-# $Id$
-# This simple demo has been developped by P. Lecoanet <lecoanet@cena.fr>
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-#
-# TODO:
-#
-# Ajouter la construction des items manquants
-#
-
-use Tk;
-use Tk::Zinc;
-
-my $currentgroup;
-my $currentitem;
-my $mw = MainWindow->new();
-my $top = 1;
-
-my $inactiveAxisColor = 'black';
-my $activeAxisColor = 'red';
-my $worldAxisColor = '#a5a5a5';
-
-my $itemtype;
-my $composerot = 1;
-my $composescale = 1;
-my $drag = 0;
-
-my $logo = $mw->Photo(-file => Tk->findINC('demos/zinc_data/zinc_anti.gif'));
-
-my $text = $mw->Text(-relief => 'sunken',
- -borderwidth => 2,
- -height => 12);
-$text->pack(-expand => 0, -fill => 'x');
-$text->insert('0.0', 'Items are always added to the current group.
-The available commands are:
- Button 1 on the background, add an item with initial translation
- Button 2 on the background, add a group with initial translation
- Button 1 on item/group axes, select/deselect that item space
- Drag Button 1 on item/group axes, translate that item space
- Del reset the transformation
- Shift-Del reset a group direct children transformations
- PageUp/Down scale up/down
- End/Home rotate right/left
- Ins swap the Y axis
- 4 arrows translate in the 4 directions');
-$text->configure(-state => 'disabled');
-
-my $zinc = $mw->Zinc(-borderwidth => 3,
- -highlightthickness => 0,
- -relief => 'sunken',
- -render => 0,
- -takefocus => 1);
-$zinc->pack(-expand => 1, -fill => 'both');
-$zinc->configure(-width => 500, -height => 500);
-
-my $rc = $mw->Frame()->pack(-expand => 0, -fill => 'x');
-my $option = $rc->Optionmenu(-options => ['rectangle', 'arc',
- 'curve',
- 'icon', 'tabular',
- 'text', 'track',
- 'triangles', 'waypoint'],
-# -command => sub { $zinc->Tk::focus(); },
- -variable => \$itemtype)->grid(-row => 0,
- -column => 1,
- -sticky => 'w');
-
-$rc->Button(-text => 'Add item',
- -command => \&additem)->grid(-row => 0,
- -column => 2,
- -padx => 10,
- -sticky => 'ew');
-$rc->Button(-text => 'Add group',
- -command => \&addgroup)->grid(-row => 0,
- -column => 3,
- -padx => 10,
- -sticky => 'ew');
-$rc->Button(-text => 'Remove',
- -command => \&removeitem)->grid(-row => 0,
- -column => 4,
- -padx => 10,
- -sticky => 'ew');
-
-$rc->Checkbutton(-text => '-composescale',
- -command => \&togglecomposescale,
- -variable => \$composescale)->grid(-row => 0,
- -column => 6,
- -sticky => 'w');
-
-$rc->Checkbutton(-text => '-composesrotation',
- -command => \&togglecomposerot,
- -variable => \$composerot)->grid(-row => 1,
- -column => 6,
- -sticky => 'w');
-
-
-my $world = $zinc->add('group', $top);
-$zinc->add('curve', $top, [0, 0, 80, 0],
- -linewidth => 3,
- -linecolor => $worldAxisColor,
- -lastend => [6,8,3],
- -tags => ["axis:$world"]);
-$zinc->add('curve', $top, [0, 0, 0, 80],
- -linewidth => 3,
- -linecolor => $worldAxisColor,
- -lastend => [6,8,3],
- -tags => ["axis:$world"]);
-$zinc->add('rectangle', $top, [-2, -2, 2, 2],
- -filled => 1,
- -fillcolor => $worldAxisColor,
- -linecolor => $worldAxisColor,
- -linewidth => 3,
- -tags => ["axis:$world"]);
-$zinc->add('text', $top,
- -text => "This is the origin\nof the world",
- -anchor => 's',
- -color => $worldAxisColor,
- -alignment => 'center',
- -tags => ["axis:$world", 'text']);
-
-
-$currentgroup = $world;
-
-$zinc->Tk::bind('<1>', [\&mouseadd, 'item']);
-$zinc->Tk::bind('<2>', [\&mouseadd, 'group']);
-$zinc->Tk::bind('<Up>', \&moveup);
-$zinc->Tk::bind('<Left>', \&moveleft);
-$zinc->Tk::bind('<Right>', \&moveright);
-$zinc->Tk::bind('<Down>', \&movedown);
-$zinc->Tk::bind('<Next>', \&scaledown);
-$zinc->Tk::bind('<Prior>', \&scaleup);
-$zinc->Tk::bind('<Delete>', \&reset);
-$zinc->Tk::bind('<Shift-Delete>', \&resetchildren);
-$zinc->Tk::bind('<End>', \&rotateleft);
-$zinc->Tk::bind('<Home>', \&rotateright);
-$zinc->Tk::bind('<Insert>', \&swapaxis);
-
-$zinc->Tk::bind('<Configure>', [\&resize]);
-
-$zinc->Tk::focus();
-$zinc->focusFollowsMouse();
-
-
-MainLoop();
-
-sub resize {
- my $ev = $zinc->XEvent();
- my $x = $ev->w/2;
- my $y = $ev->h/2;
-
- $zinc->treset($world);
- $zinc->treset("axis:$world");
- $zinc->translate($world, $x, $y);
- $zinc->translate("axis:$world", $x, $y);
-}
-
-sub swapaxis {
- if (defined($currentitem)) {
- $zinc->scale($currentitem, 1, -1);
- $zinc->scale("axisgrp:$currentitem", 1, -1);
- }
-}
-
-sub togglecomposerot {
- if (defined($currentitem)) {
- $zinc->itemconfigure($currentitem, -composerotation => $composerot);
- $zinc->itemconfigure("axisgrp:$currentitem", -composerotation => $composerot);
- }
-}
-
-sub togglecomposescale {
- my $bool;
-
- if (defined($currentitem)) {
- $zinc->itemconfigure($currentitem, -composescale => $composescale);
- $zinc->itemconfigure("axisgrp:$currentitem", -composescale => $composescale);
- }
-}
-
-sub dragitem {
- $drag = 1;
- return if (!defined($currentitem));
-
- my $ev = $zinc->XEvent();
- my $group = $zinc->group($currentitem);
- my ($x, $y) = $zinc->transform($group, [$ev->x, $ev->y]);
-
- $zinc->treset($currentitem);
- $zinc->treset("axisgrp:$currentitem");
- $zinc->translate($currentitem, $x, $y);
- $zinc->translate("axisgrp:$currentitem", $x, $y);
-}
-
-sub select {
- my @tags = $zinc->gettags('current');
- my $t;
- foreach $t (@tags) {
- if ($t =~ '^axis:(\d+)') {
- changeitem($1);
- }
- }
-}
-
-sub changeitem {
- my ($item) = @_;
-
- if (defined($currentitem) && !$drag) {
- $zinc->itemconfigure("axis:$currentitem && !text",
- -linecolor => $inactiveAxisColor,
- -fillcolor => $inactiveAxisColor);
- if ($currentitem != $currentgroup) {
- $zinc->itemconfigure("axis:$currentitem && !text",
- -linewidth => 1);
- }
- }
- if (!defined($currentitem) || ($item != $currentitem)) {
- $zinc->itemconfigure("axis:$item && !text",
- -linecolor => $activeAxisColor,
- -fillcolor => $activeAxisColor,
- -linewidth => 3);
- $currentitem = $item;
- $composerot = $zinc->itemcget($currentitem, -composerotation);
- $zinc->itemconfigure("axisgrp:$currentitem", -composerotation => $composerot);
- $composescale = $zinc->itemcget($currentitem, -composescale);
- $zinc->itemconfigure("axisgrp:$currentitem", -composescale => $composescale);
- }
- elsif (!$drag) {
- $currentitem = undef;
- $composerot = $composescale = 1;
- }
- $drag = 0;
-}
-
-sub selectgroup {
- my @tags = $zinc->gettags('current');
- my $t;
- foreach $t (@tags) {
- if ($t =~ '^axis:(\d+)') {
- changegroup($1);
- }
- }
-}
-
-sub changegroup {
- my ($grp) = @_;
-
- changeitem($grp);
- $zinc->itemconfigure("axis:$currentgroup && !text",
- -linewidth => 1);
- if (defined($currentitem)) {
- $currentgroup = $currentitem;
- }
- else {
- $currentgroup = $world;
- }
-
- $zinc->itemconfigure("axis:$currentgroup && !text",
- -linewidth => 3);
-}
-
-sub reset {
- if (defined($currentitem)) {
- $zinc->treset($currentitem);
- $zinc->treset("axisgrp:$currentitem");
- }
-}
-
-sub resetchildren {
- my @children;
-
- if (defined($currentitem) && ($zinc->type($currentitem) eq 'group')) {
- @children = $zinc->addtag('rt', 'withtag', 'all', $currentitem, 0);
- $zinc->treset('rt');
- $zinc->dtag('rt', 'rt');
- }
-}
-
-sub moveup {
- move(0, 20);
-}
-
-sub movedown {
- move(0, -20);
-}
-
-sub moveright {
- move(20, 0);
-}
-
-sub moveleft {
- move(-20, 0);
-}
-
-sub move {
- my ($dx, $dy) = @_;
-
- if (defined($currentitem)) {
- $zinc->translate($currentitem, $dx, $dy);
- $zinc->translate("axisgrp:$currentitem", $dx, $dy);
- }
-}
-
-sub scaleup {
- scale(1.1, 1.1);
-}
-
-sub scaledown {
- scale(0.9, 0.9);
-}
-
-sub scale {
- my ($dx, $dy) = @_;
-
- if (defined($currentitem)) {
- $zinc->scale($currentitem, $dx, $dy);
- $zinc->scale("axisgrp:$currentitem", $dx, $dy);
- }
-}
-
-sub rotateleft {
- rotate(-3.14159/18);
-}
-
-sub rotateright {
- rotate(3.14159/18);
-}
-
-sub rotate {
- my ($angle) = @_;
-
- if (defined($currentitem)) {
- $zinc->rotate($currentitem, $angle);
- $zinc->rotate("axisgrp:$currentitem", $angle);
- }
-}
-
-sub newrect {
- return $zinc->add('rectangle', $currentgroup,
- [-15, -15, 15, 15],
- -filled => 1,
- -linewidth => 0,
- -fillcolor => 'tan');
-}
-
-sub newarc {
- return $zinc->add('arc', $currentgroup,
- [-25, -15, 25, 15],
- -filled => 1,
- -linewidth => 0,
- -fillcolor => 'tan');
-}
-
-sub newcurve {
- return $zinc->add('curve', $currentgroup,
- [-15, -15, -15, 15, 15, 15, 15, -15],
- -filled => 1,
- -linewidth => 0,
- -fillcolor => 'tan');
-}
-
-sub newtext {
- my $item = $zinc->add('text', $currentgroup,
- -anchor => 's');
- $zinc->itemconfigure($item, -text => "Item id: $item");
- return $item;
-}
-
-sub newicon {
- my $item = $zinc->add('icon', $currentgroup,
- -image => $logo,
- -anchor => 'center');
-
- return $item;
-}
-
-sub newtriangles {
- my $item = $zinc->add('triangles', $currentgroup,
- [-25, 15, -10, -15, 5, 15,
- 20, -15, 35, 15, 50, -30],
- -colors => ['tan', 'wheat', 'tan', 'wheat']);
- return $item;
-}
-
-sub newtrack {
- my $labelformat = "x80x50+0+0 a0a0^0^0 a0a0^0>1 a0a0>2>1 x30a0>3>1 a0a0^0>2";
-
- my $item=$zinc->add('track', $currentgroup, 6,
- -labelformat => $labelformat,
- -speedvector => [30, -15],
- -markersize => 20);
- $zinc->itemconfigure($item, 0,
- -filled => 0,
- -bordercolor => 'DarkGreen',
- -border => 'contour');
- $zinc->itemconfigure($item, 1,
- -filled => 1,
- -backcolor => 'gray60',
- -text => 'AFR6128');
- $zinc->itemconfigure($item, 2,
- -filled => 0,
- -backcolor => 'gray65',
- -text => '390');
- $zinc->itemconfigure($item, 3,
- -filled => 0,
- -backcolor => 'gray65',
- -text => '/');
- $zinc->itemconfigure($item, 4,
- -filled => 0,
- -backcolor => 'gray65',
- -text => '350');
- $zinc->itemconfigure($item, 5,
- -filled => 0,
- -backcolor => 'gray65',
- -text => 'TUR');
- return $item;
-}
-
-sub newwaypoint {
- my $labelformat = "a0a0+0+0 a0a0>0^1";
-
- my $item=$zinc->add('waypoint', $currentgroup, 2,
- -labelformat => $labelformat);
- $zinc->itemconfigure($item, 0,
- -filled => 1,
- -backcolor => 'DarkGreen',
- -text => 'TUR');
- $zinc->itemconfigure($item, 1,
- -text => '>>>');
- return $item;
-}
-
-sub newtabular {
- my $labelformat = "f700f600+0+0 f700a0^0^0 f700a0^0>1 f700a0^0>2 f700a0^0>3 f700a0^0>4 f700a0^0>5";
-
- my $item=$zinc->add('tabular', $currentgroup, 7,
- -labelformat => $labelformat);
- $zinc->itemconfigure($item, 0,
- -filled => 1,
- -border => 'contour',
- -bordercolor => 'black',
- -backcolor => 'gray60');
- $zinc->itemconfigure($item, 1,
- -alignment => 'center',
- -text => 'AFR6128');
- $zinc->itemconfigure($item, 2,
- -alignment => 'center',
- -text => '390');
- $zinc->itemconfigure($item, 3,
- -alignment => 'center',
- -text => '370');
- $zinc->itemconfigure($item, 4,
- -alignment => 'center',
- -text => '350');
- $zinc->itemconfigure($item, 5,
- -alignment => 'center',
- -text => '330');
- $zinc->itemconfigure($item, 6,
- -alignment => 'center',
- -text => 'TUR');
- return $item;
-}
-
-sub addaxes {
- my ($item, $length, $command, $infront) = @_;
-
- my $axesgroup = $zinc->add('group', $currentgroup,
- -tags => ["axisgrp:$item"]);
- $zinc->add('curve', $axesgroup, [0, 0, $length, 0],
- -linewidth => 2,
- -lastend => [6,8,3],
- -tags => ["axis:$item"]);
- $zinc->add('curve', $axesgroup, [0, 0, 0, $length],
- -linewidth => 2,
- -lastend => [6,8,3],
- -tags => ["axis:$item"]);
- $zinc->add('rectangle', $axesgroup, [-2, -2, 2, 2],
- -filled => 1,
- -linewidth => 0,
- -composescale => 0,
- -tags => ["axis:$item"]);
- if ($infront) {
- $zinc->raise($item, $axesgroup);
- }
- $zinc->bind("axis:$item", '<B1-Motion>', \&dragitem);
- $zinc->bind("axis:$item", '<ButtonRelease-1>', $command);
-}
-
-sub additem {
- my $item;
- my $length = 25;
- my $itemontop = 0;
-
- if ($itemtype eq 'rectangle') {
- $item = newrect();
- }
- elsif ($itemtype eq 'arc') {
- $item = newarc();
- }
- elsif ($itemtype eq 'curve') {
- $item = newcurve();
- }
- elsif ($itemtype eq 'triangles') {
- $item = newtriangles();
- }
- elsif ($itemtype eq 'icon') {
- $item = newicon();
- }
- elsif ($itemtype eq 'text') {
- $item = newtext();
- }
- elsif ($itemtype eq 'track') {
- $item = newtrack();
- $itemontop = 1;
- }
- elsif ($itemtype eq 'waypoint') {
- $item = newwaypoint();
- $itemontop = 1;
- }
- elsif ($itemtype eq 'tabular') {
- $item = newtabular();
- }
-
- addaxes($item, 25, \&select, $itemontop);
- changeitem($item);
-}
-
-sub addgroup {
- my $item = $zinc->add('group', $currentgroup);
-
- addaxes($item, 80, \&selectgroup, 1);
- changegroup($item);
-}
-
-sub mouseadd {
- my ($w, $itemorgrp) = @_;
- my $ev = $zinc->XEvent();
- my ($x, $y) = $zinc->transform($currentgroup, [$ev->x, $ev->y]);
- my $item = $zinc->find('withtag', 'current');
-
- if (defined($item)) {
- my @tags = $zinc->gettags($item);
- foreach my $t (@tags) {
- return if ($t =~ '^axis');
- }
- }
- if ($itemorgrp eq 'group') {
- addgroup();
- }
- else {
- additem();
- }
- $zinc->translate($currentitem, $x, $y);
- $zinc->translate("axisgrp:$currentitem", $x, $y);
-}
-
-sub removeitem {
- if (defined($currentitem)) {
- $zinc->remove($currentitem, "axisgrp:$currentitem");
- if ($currentitem == $currentgroup) {
- $currentgroup = $world;
- }
- $currentitem = undef;
- $composescale = $composerot = 1;
- }
-}
diff --git a/Perl/demos/Tk/demos/zinc_lib/translation.pl b/Perl/demos/Tk/demos/zinc_lib/translation.pl
deleted file mode 100644
index f6abb15..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/translation.pl
+++ /dev/null
@@ -1,144 +0,0 @@
-#!/usr/bin/perl
-# $Id$
-# This simple demo has been developped by C. Schlienger <celine@intuilab.com>
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-
-use Tk;
-use Tk::Zinc;
-use strict;
-
-
-my $defaultfont = '-adobe-helvetica-bold-r-normal--*-120-*-*-*-*-*-*';
-my $mw = MainWindow->new();
-
-###########################################
-# Text zone
-###########################################
-
-my $text = $mw->Scrolled(qw/Text -relief sunken -borderwidth 2 -setgrid true
- -height 6 -scrollbars e/);
-$text->pack(qw/-expand yes -fill both/);
-
-$text->insert('0.0',
- 'This toy-appli shows translations on waypoint items.
-The following operations are possible:
- Click "Up" for up translation
- Click "Left" for left translation
- Click "Right" for right translation
- Click "Down" for down translation' );
-
-###########################################
-# Zinc
-###########################################
-my $zinc_width=600;
-my $zinc_height=400;
-my $zinc = $mw->Zinc(-width => $zinc_width, -height => $zinc_height,
- -font => "10x20",
- -borderwidth => 3, -relief => 'sunken',
- )->pack;
-
-###########################################
-# Waypoints
-###########################################
-
-my $wp_group = $zinc->add('group', 1, -visible => 1);
-
-my $p1=[200, 200];
-my $wp1 = $zinc->add('waypoint',$wp_group, 1,
- -position => $p1,
- -connectioncolor => 'green',
- -symbolcolor => 'blue',
- -labelformat => 'x20x18+0+0',
- -leaderwidth=>'0',
- -labeldx=>'-20'
- );
-$zinc->itemconfigure($wp1, 0,
- -text => "DO",
- );
-
-my $p2=[300, 300];
-my $wp2 = $zinc->add('waypoint',$wp_group, 1,
- -position => $p2,
- -connecteditem => $wp1,
- -connectioncolor => 'blue',
- -symbolcolor => 'blue',
- -labelformat => 'x20x18+0+0',
- -leaderwidth=>'0',
- -labeldx=>'-20',
- #-labeldy=>'30'
- );
-
-$zinc->itemconfigure($wp2, 0,
- -text => "RE",
- );
-
-my $p3=[400, 150];
-my $wp3 = $zinc->add('waypoint', $wp_group, 2,
- -position => $p3,
- -connecteditem => $wp2,
- -connectioncolor => 'blue',
- -symbolcolor => 'blue',
- -labelformat => 'x20x18+0+0',
- -leaderwidth=>'0',
- -labeldx=>'20',
- -labeldy=>'+10'
- );
-$zinc->itemconfigure($wp3, 0,
- -text => "MI",
- );
-
-###################################################
-# control panel
-###################################################
-my $rc = $mw->Frame()->pack();
-my $up=$rc->Button(-width => 2,
- -height => 2,
- -text => 'Up',
- -command=>sub{
- #--------------------------------
- # Up translation
- #--------------------------------
- $zinc->translate("$wp_group",0,-10);
- })->grid(-row => 0,
- -column => 1);
-
-my $left=$rc->Button(-width => 2,
- -height => 2,
- -text => 'Left',
- -command=>sub{
- #--------------------------------
- # Left translation
- #--------------------------------
- $zinc->translate("$wp_group",-10,0);
- })->grid(-row => 1,
- -column => 0);
-
-my $right=$rc->Button(-width => 2,
- -height => 2,
- -text => 'Right',
- -command=>sub{
- #--------------------------------
- # Right translation
- #--------------------------------
- $zinc->translate("$wp_group",10,0);
- })->grid(-row => 1,
- -column => 2);
-
-my $down=$rc->Button(-width => 2,
- -height => 2,
- -text => 'Down',
- -command=>sub{
- #--------------------------------
- # Down translation
- #--------------------------------
- $zinc->translate("$wp_group",0,10);
- })->grid(-row => 2,
- -column => 1);
-
-
-
-
-MainLoop;
diff --git a/Perl/demos/Tk/demos/zinc_lib/triangles.pl b/Perl/demos/Tk/demos/zinc_lib/triangles.pl
deleted file mode 100644
index 2dfba41..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/triangles.pl
+++ /dev/null
@@ -1,58 +0,0 @@
-#!/usr/bin/perl
-# $Id$
-# these simple samples have been developped by C. Mertz mertz@cena.fr and N. Banoun banoun@cena.fr
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-use Tk::Zinc;
-use strict;
-
-
-my $defaultfont = '-adobe-helvetica-bold-r-normal--*-120-*-*-*-*-*-*';
-my $mw = MainWindow->new();
-my $zinc = $mw->Zinc(-width => 700, -height => 300,
- -font => "10x20", # usually fonts are sets in resources
- # but for this example it is set in the code!
- -render => 1,
- -borderwidth => 3, -relief => 'sunken',
- )->pack;
-
-# 6 equilateral triangles around a point
-$zinc->add('text', 1,
- -position => [ 5,10 ],
- -text => "Triangles item without transparency");
-
-my ($x0,$y0) = (200,150);
-my @coords=($x0,$y0);
-for my $i (0..6) {
- my $angle = $i * 6.28/6;
- push @coords, ($x0 + 100 * cos ($angle), $y0 - 100 * sin ($angle) );
-}
-
-my $tr1 = $zinc->add('triangles', 1,
- \@coords,
- -fan => 1,
- -colors => ['white', 'yellow', 'magenta', 'blue', 'cyan', 'green', 'red', 'yellow'],
- -visible => 1,
- );
-
-$zinc->add('text', 1,
- -position => [ 370, 10 ],
- -text => "Triangles item with transparency");
-
-
-# using the clone method to make a copy and then modify the clone'colors
-my $tr2 = $zinc->clone($tr1);
-$zinc->translate($tr2,300,0);
-$zinc->itemconfigure($tr2,
- -colors => ['white;50', 'yellow;50', 'magenta;50', 'blue;50', 'cyan;50', 'green;50', 'red;50', 'yellow;50'],
- );
-
-
-
-MainLoop;
-
-
-
diff --git a/Perl/demos/Tk/demos/zinc_lib/wheelOfFortune.pl b/Perl/demos/Tk/demos/zinc_lib/wheelOfFortune.pl
deleted file mode 100644
index cf117a5..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/wheelOfFortune.pl
+++ /dev/null
@@ -1,374 +0,0 @@
-#!/usr/bin/perl
-#
-# This short script tries to demonstrate with a simple example what you can
-# do with Tk Zinc widget, in particular how to use group item, clipping, and
-# transformations.
-# $Id$
-# this demo has been developped by D. Etienne etienne@cena.fr
-#
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-# Zinc module is loaded...
-use Tk::Zinc;
-
-
-# We create a classical root widget called MainWindow; then we create Zinc
-# widget child with size, color and relief attributes, and we display it using
-# the geometry manager called 'pack'.
-my $mw = MainWindow->new;
-$mw->geometry("320x565");
-$mw->resizable(0,0);
-my $zinc = $mw->Zinc(-width => 300, -height => 500, -backcolor => 'gray70',
- -borderwidth => 3, -relief => 'sunken');
-$zinc->pack;
-
-# Then we create a gray filled rectangle, in which we will display explain text.
-$zinc->add('rectangle', 1 , [10, 400, 290, 490],
- -linewidth => 0,
- -filled => 1,
- -fillcolor => 'gray80',
- );
-my $text = $zinc->add('text', 1,
- -position => [150, 445],
- -anchor => 'center',
- );
-
-# Create the Wheel object (see Wheel.pm)
-my $wheel = Wheel->new($zinc, 150, 500, 100);
-
-# Display comment
-&comment("Strike any key to begin");
-
-# Create Tk binding
-$mw->Tk::bind('<Key>', \&openmode);
-
-
-
-MainLoop;
-
-
-
-# Callback bound to '<Key>' event when wheel is unmapped
-sub openmode {
- return if $wheel->ismoving;
- # set binding to unmap the wheel
- $mw->Tk::bind('<Key>', \&closemode);
- # set binding to rotate the hand
- $zinc->bind($wheel, '<1>', sub {$wheel->rotatehand(300)});
- # map the wheel
- $wheel->show(150, 150);
- # and then inform user
- &comment("Click on the wheel to rotate the hand.\n".
- "Strike any other key to hide the wheel.");
-}
-
-# Callback bound to '<Key>' event when wheel is already mapped
-sub closemode {
- return if $wheel->ismoving;
- # set binding to map the wheel
- $mw->Tk::bind('<Key>', \&openmode);
- # unmap the wheel
- $wheel->hide(150, 400);
- # and then inform user
- &comment("Strike any key to show the wheel");
-}
-
-# Just display comment
-sub comment {
- my $string = shift;
- $zinc->itemconfigure($text, -text => $string);
-}
-
-
-
-#=============================================================================
-# Wheel Class
-#=============================================================================
-package Wheel;
-
-use strict 'vars';
-use Carp;
-
-
-#====================
-# Object constructor
-#====================
-sub new {
- my ($proto, $widget, $x, $y, $radius) = @_;
-
- # object attributes
- my $self = {
- 'widget' => $widget, # widget reference
- 'origin' => [$x, $y], # origin coordinates
- 'radius' => $radius, # wheel radius
- 'topgroup' => undef, # top Group item
- 'itemclip' => undef, # id of item which clips the wheel
- 'hand' => undef, # id of item wich represents the hand
- 'angle' => 60, # the angle between hand and jackpot
- 'stepsnumber' => 10, # animations parameters
- 'afterdelay' => 60,
- 'shrinkrate' => 0.8, # zoom parameters
- 'zoomrate' => 1.1
- };
- bless $self;
-
- # First, we create a new Group item for the wheel. Why a Group item ?
- # At least two reasons. Wheel object consists of several Zinc items,
- # we'll see below; it moves when it is mapped or unmapped, grows when
- # you hit the jackpot. So, it's more easy to apply such transformations
- # to a structured items set, using Group capability, rather than apply
- # to each item separately or using canvas-like Tags mechanism.
- # Second reason refers to clipping. When it is mapped or unmapped, wheel
- # object is drawn inside a circle with variant radius; clipping is a
- # specific property of Group item
-
- # That's why we create a Group item in the top group, and set its
- # coordinates.
- $self->{topgroup} = $widget->add('group', 1, -visible => 0);
- $widget->coords($self->{topgroup}, [$x, $y]);
- # All the following items will be created in this group...
-
- # Create the invisible Arc item used to clip the wheel, centered on the
- # group origin.
- $self->{itemclip} = $widget->add('arc', $self->{topgroup},
- [-$radius, -$radius, $radius, $radius],
- -visible => 0,
- );
- $widget->itemconfigure($self->{topgroup}, -clip => $self->{itemclip});
-
- # Create the wheel with 6 filled Arc items centered on the group origin
- my $i = 0;
- for my $color (qw(magenta blue cyan green yellow red)) {
- $widget->add('arc', $self->{topgroup},
- [-$radius, -$radius, $radius, $radius],
- -visible => 1,
- -filled => 1,
- -closed => 1,
- -extent => 60,
- -pieslice => 1,
- -fillcolor => $color,
- -linewidth => 0,
- -startangle => 60*$i ,
- -tags => [$self],
- );
- $i++;
- }
-
- # Create the Text item representing the jackpot.
- $widget->add('text', $self->{topgroup},
- -position => [0, -$radius+20],
- -font =>
- '-adobe-helvetica-bold-o-normal--34-240-100-100-p-182-iso8859-1',
- -anchor => 'center',
- -text => "\$",
- );
-
- # Create the closed Curve item representing the hand.
- # In order to make processing easier, its rotation axis will be placed
- # on the group origin.
- $self->{hand} = $widget->add('curve', $self->{topgroup},
- [0, -$radius + 10, 20, -$radius + 40,
- 6, -$radius + 40, 20, 10,
- -20, 10, -6, -$radius + 40,
- -20, -$radius + 40],
- -linewidth => 3,
- -linecolor => 'gray40',
- -filled => 1,
- -fillcolor => 'gray80',
- -closed => 1,
- -tags => [$self]);
- # Then, we apply rotation to the hand using the Zinc 'rotation' method.
- $widget->rotate($self->{hand}, 3.1416/3);
-
- # Then we unmap the wheel; in fact, Group item is translated and its
- # clipping circle is shrunk to a point.
- $self->_clipAndTranslate($self->{shrinkrate}**$self->{stepsnumber});
-
- return $self;
-
-}
-
-#================
-# Public methods
-#================
-
-# Return 1 if wheel is moving (opening or closing animation)
-sub ismoving {
- my $self = shift;
- return 1 if $self->{opening} or $self->{closing};
-}
-
-# Display wheel with animation effect
-sub show {
- my ($self, $x, $y) = @_;
- # simple lock management
- return if $self->{opening} or $self->{closing};
- $self->{opening} = 1;
- # start animation
- $self->_open($x, $y, 0);
-}
-
-
-# Unmap wheel with animation effect
-sub hide {
- my ($self, $x, $y) = @_;
- # simple lock management
- return if $self->{opening} or $self->{closing};
- $self->{closing} = 1;
- # start animation
- $self->_close($x, $y, 0);
-}
-
-
-# Just rotate the hand with animation effect.
-sub rotatehand {
- my $self = shift;
- my $angle = shift;
- return if $self->{turning};
- $angle = 360 unless $angle;
- $self->{angle} += $angle;
- if ($self->{angle} % 360 == 0) {
- $self->{fortune} = 1;
- }
- $self->_rotatehand(2*3.1416*$angle/360);
-}
-
-
-#=================
-# Private methods
-#=================
-
-# Generate opening animation; see below _clipAndTranslate method for
-# Zinc specific use.
-sub _open {
- my ($self, $x, $y, $cnt) = @_;
- my $widget = $self->{widget};
- my $group = $self->{topgroup};
- # first step of animation
- if ($cnt == 0) {
- $widget->itemconfigure($group, -visible => 1);
- my @pos = $widget->coords($group);
- $x = ($x - $pos[0])/$self->{stepsnumber};
- $y = ($y - $pos[1])/$self->{stepsnumber};
- # last step
- } elsif ($cnt == $self->{stepsnumber}) {
- $self->{opening} = undef;
- return;
- }
- $cnt++;
- # move and grow the wheel
- $self->_clipAndTranslate(1/$self->{shrinkrate}, $x, $y);
- # process the animation using the 'after' Tk defering method
- $widget->after($self->{afterdelay}, sub {$self->_open($x, $y, $cnt)});
-}
-
-
-# Generate closing animation; see below _clipAndTranslate method for
-# Zinc specific use.
-sub _close {
- my ($self, $x, $y, $cnt) = @_;
- my $widget = $self->{widget};
- my $group = $self->{topgroup};
- # first step of animation
- if ($cnt == 0) {
- my @pos = $widget->coords($group);
- $x = ($x - $pos[0])/$self->{stepsnumber};
- $y = ($y - $pos[1])/$self->{stepsnumber};
- # last step
- } elsif ($cnt == $self->{stepsnumber}) {
- $widget->itemconfigure($group, -visible => 0);
- $self->{closing} = undef;
- return;
- }
- $cnt++;
- # move and shrink the wheel
- $self->_clipAndTranslate($self->{shrinkrate}, $x, $y);
- # process the animation using the 'after' Tk defering method
- $widget->after($self->{afterdelay}, sub {$self->_close($x, $y, $cnt)});
-}
-
-
-# Generate hand rotation animation.
-sub _rotatehand {
- my ($self, $angle, $cnt) = @_;
- my $widget = $self->{widget};
- my $group = $self->{topgroup};
- $self->{turning} = 1;
- # first step of animation
- if (not $cnt) {
- $angle /= $self->{stepsnumber};
- # last step
- } elsif ($cnt == $self->{stepsnumber}) {
- if ($self->{fortune}) {
- $self->_fortune;
- } else {
- $self->{turning} = undef;
- }
- return;
- }
- $cnt++;
- # use 'rotation' Zinc method.
- $widget->rotate($self->{hand}, $angle);
-
- # process the animation using the 'after' Tk defering method
- $widget->after($self->{afterdelay}, sub {$self->_rotatehand($angle, $cnt)});
-
-}
-
-# Generate growing animation to notify jackpot
-sub _fortune {
- my ($self, $cnt) = @_;
- $cnt = 0 unless $cnt;
- my $zf;
- my $widget = $self->{widget};
- my $group = $self->{topgroup};
- my @pos = $widget->coords($group);
- # last step of animation
- if ($cnt == 6) {
- $self->{fortune} = undef;
- $self->{turning} = undef;
- return;
- # event steps : wheel grows
- } elsif ($cnt == 0 or $cnt % 2 == 0) {
- $zf = $self->{zoomrate};
- # odd steps : wheel is shrunk
- } else {
- $zf = 1/$self->{zoomrate};
- }
- $cnt++;
-
- # Now, we apply scale transformation to the Group item, using the 'scale'
- # Zinc method. Note that we reset group coords before scaling it, in order
- # that the origin of the transformation corresponds to the center of the
- # wheel. When scale is done, we restore previous coords of group.
- $widget->coords($group, [0, 0]);
- $widget->scale($group, $zf, $zf);
- $widget->coords($group, \@pos);
-
- # process the animation using the 'after' Tk defering method
- $widget->after(100, sub {$self->_fortune($cnt)});
-
-}
-
-# Update group clipping and translation, using 'scale' and 'translate'
-# Zinc methods.
-sub _clipAndTranslate {
-
- my ($self, $shrinkfactor, $x, $y) = @_;
- $x = 0 unless $x;
- $y = 0 unless $y;
- $self->{widget}->scale($self->{itemclip}, $shrinkfactor, $shrinkfactor);
- if ($Tk::Zinc::VERSION lt "3.297") {
- $self->{widget}->translate($self->{topgroup}, $x, $y);
- } else {
- my ($xc, $yc) = $self->{widget}->coords($self->{topgroup});
- $self->{widget}->coords($self->{topgroup}, [$xc + $x, $yc + $y]);
- }
-
-}
-
-
-1;
diff --git a/Perl/demos/Tk/demos/zinc_lib/window-contours.pl b/Perl/demos/Tk/demos/zinc_lib/window-contours.pl
deleted file mode 100644
index 9f16f95..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/window-contours.pl
+++ /dev/null
@@ -1,112 +0,0 @@
-#!/usr/bin/perl -w
-# $Id$
-# This simple demo has been developped by C. Mertz <mertz@cena.fr>
-
-package window_contours; # for avoiding symbol collision between different demos
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-use Tk::Zinc;
-
-use strict;
-
-my $mw = MainWindow->new();
-
-
-# Creating the zinc widget
-my $zinc = $mw->Zinc(-width => 600, -height => 500,
- -font => "9x15", # usually fonts are sets in resources
- # but for this example it is set in the code!
- -borderwidth => 3, -relief => 'sunken',
- )->pack;
-
-# The explanation displayed when running this demo
-$zinc->add('text', 1,
- -position=> [10,10],
- -text => 'These "windows" are simply rectangles holed by 4 smaller
-rectangles. The text appears behind the window glasses.
-You can drag text or "windows".',
- -font => "10x20",
- );
-
-# Text in background
-my $backtext = $zinc->add('text', 1,
- -position=> [50,200],
- -text => "This text appears\nthrough holes of curves",
- -font => "-adobe-helvetica-bold-o-normal--34-240-100-100-p-182-iso8859-1",
- );
-
-my $window = $zinc->add('curve', 1, [100,100 , 300,100, 300,400 , 100,400 ],
- -closed => 1, -visible => 1, -filled => 1,
- -fillcolor => "grey66",
- );
-
-my $aGlass= $zinc->add('rectangle', 1, [120,120 , 190,240]);
-$zinc->contour($window, 'add', +1, $aGlass);
-
-$zinc->translate($aGlass, 90,0);
-$zinc->contour($window, 'add', +1, $aGlass);
-
-$zinc->translate($aGlass, 0,140);
-$zinc->contour($window, 'add', +1, $aGlass);
-
-$zinc->translate($aGlass, -90,0);
-$zinc->contour($window, 'add', +1, $aGlass);
-
-# deleting $aGlass which is no more usefull
-$zinc->remove($aGlass);
-
-# cloning $window
-my $window2 = $zinc->clone($window);
-
-# changing its background, moving it and scaling it!
-$zinc->itemconfigure($window2, -fillcolor => "grey50");
-$zinc->translate($window2, 30,50);
-$zinc->scale($window, 0.8, 0.8);
-
-
-
-
-# adding drag and drop callback to the two windows and backtext
-foreach my $item ($window, $window2, $backtext) {
- # Some bindings for dragging the items
- $zinc->bind($item, '<ButtonPress-1>' => [\&press, $item, \&motion]);
- $zinc->bind($item, '<ButtonRelease-1>' => \&release);
-}
-
-# callback for starting a drag
-my ($x_orig, $y_orig);
-sub press {
- my ($zinc, $item, $action) = @_;
- my $ev = $zinc->XEvent();
- $x_orig = $ev->x;
- $y_orig = $ev->y;
- $zinc->Tk::bind('<Motion>', [$action, $item]);
-}
-
-# Callback for moving an item
-sub motion {
- my ($zinc, $item) = @_;
- my $ev = $zinc->XEvent();
- my $x = $ev->x;
- my $y = $ev->y;
-
- $zinc->translate($item, $x-$x_orig, $y-$y_orig);
- $x_orig = $x;
- $y_orig = $y;
-}
-
-
-# Callback when releasing the mouse button. It removes any motion callback
-sub release {
- my ($zinc) = @_;
- $zinc->Tk::bind('<Motion>', '');
-}
-
-
-Tk::MainLoop();
-
-
-1;
diff --git a/Perl/demos/Tk/demos/zinc_lib/zoom.pl b/Perl/demos/Tk/demos/zinc_lib/zoom.pl
deleted file mode 100644
index a1ad925..0000000
--- a/Perl/demos/Tk/demos/zinc_lib/zoom.pl
+++ /dev/null
@@ -1,180 +0,0 @@
-#!/usr/bin/perl
-# $Id$
-# This simple demo has been developped by C. Schlienger <celine@intuilab.com>
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-
-use Tk;
-use Tk::Zinc;
-use strict;
-
-
-my $defaultfont = '-adobe-helvetica-bold-r-normal--*-120-*-*-*-*-*-*';
-my $mw = MainWindow->new();
-
-###########################################
-# Text zone
-###########################################
-
-my $text = $mw->Text(-relief => 'sunken', -borderwidth => 2, -height => 4);
-$text->pack(qw/-expand yes -fill both/);
-
-$text->insert('0.0',
- 'This toy-appli shows zoom actions on waypoint and curve items.
-The following operations are possible:
- Click "-" to zoom out
- Click "+" to zoom in ' );
-
-###########################################
-# Zinc
-###########################################
-my $zinc_width=600;
-my $zinc_height=500;
-my $zinc = $mw->Zinc(-width => $zinc_width, -height => $zinc_height,
- -font => "10x20",
- -borderwidth => 3, -relief => 'sunken',
- )->pack;
-
-###########################################
-# Waypoints and sector
-###########################################
-
-my $wp_group = $zinc->add('group', 1, -visible => 1);
-
-my $p1=[200, 100];
-my $wp1 = $zinc->add('waypoint',$wp_group, 1,
- -position => $p1,
- -connectioncolor => 'green',
- -symbolcolor => 'blue',
- -labelformat => 'x20x18+0+0',
- -leaderwidth=>'0',
- -labeldx=>'-20'
- );
-$zinc->itemconfigure($wp1, 0,
- -text => "DO",
- );
-
-my $p2=[300, 150];
-my $wp2 = $zinc->add('waypoint',$wp_group, 1,
- -position => $p2,
- -connecteditem => $wp1,
- -connectioncolor => 'blue',
- -symbolcolor => 'blue',
- -labelformat => 'x20x18+0+0',
- -leaderwidth=>'0',
- -labeldx=>'-20',
- );
-
-$zinc->itemconfigure($wp2, 0,
- -text => "RE",
- );
-
-my $p3=[400, 50];
-my $wp3 = $zinc->add('waypoint', $wp_group, 2,
- -position => $p3,
- -connecteditem => $wp2,
- -connectioncolor => 'blue',
- -symbolcolor => 'blue',
- -labelformat => 'x20x18+0+0',
- -leaderwidth=>'0',
- -labeldx=>'20',
- -labeldy=>'+10'
- );
-$zinc->itemconfigure($wp3, 0,
- -text => "MI",
- );
-
-my $p4=[350, 450];
-my $wp4 = $zinc->add('waypoint', $wp_group, 2,
- -position => $p4,
- -connecteditem => $wp2,
- -connectioncolor => 'blue',
- -symbolcolor => 'blue',
- -labelformat => 'x20x18+0+0',
- -leaderwidth=>'0',
- -labeldy=>'-15'
- );
-$zinc->itemconfigure($wp4, 0,
- -text => "FA",
- );
-
-
-my $p5=[300, 250];
-my $wp5 = $zinc->add('waypoint', $wp_group, 2,
- -position => $p5,
- -connectioncolor => 'blue',
- -symbolcolor => 'blue',
- -labelformat => 'x20x18+0+0',
- -leaderwidth=>'0',
- -labeldy=>'-15'
- );
-$zinc->itemconfigure($wp5, 0,
- -text => "SOL",
- );
-
-
-my $p6=[170, 240];
-my $wp6 = $zinc->add('waypoint', $wp_group, 2,
- -position => $p6,
- -connecteditem => $wp5,
- -connectioncolor => 'blue',
- -symbolcolor => 'blue',
- -labelformat => 'x20x18+0+0',
- -leaderwidth=>'0',
- -labeldx=>'-20'
- );
-$zinc->itemconfigure($wp6, 0,
- -text => "LA",
- );
-
-my $p7=[550, 200];
-my $wp7 = $zinc->add('waypoint', $wp_group, 2,
- -position => $p7,
- -connecteditem => $wp5,
- -connectioncolor => 'blue',
- -symbolcolor => 'blue',
- -labelformat => 'x20x18+0+0',
- -leaderwidth=>'0',
- -labeldx=>'20'
- );
-$zinc->itemconfigure($wp7, 0,
- -text => "SI",
- );
-
-
-my $sector = $zinc ->add('curve',$wp_group,[300,0,400,50,500,100,550,200,550,400,350,450,170,240,200,100,300,0]);
-
-###################################################
-# control panel
-###################################################
-my $rc = $mw->Frame()->pack();
-
-#the reference of the scale function is top-left corner of the zinc object
-#so we first translate the group to zoom in order to put its center on top-left corner
-#change the scale of the group
-#translate the group to put it back at the center of the zinc object
-
-my $minus=$rc->Button(-width => 2,
- -height => 2,
- -text => '-',
- -command=>sub{
- $zinc->translate($wp_group,-$zinc_width/2,-$zinc_height/2);
- $zinc->scale($wp_group,0.8,0.8);
- $zinc->translate($wp_group, $zinc_width/2,$zinc_height/2);
- })->pack(-side=>'left');
-
-
-my $plus=$rc->Button(-width => 2,
- -height => 2,
- -text => '+',
- -command=>sub{
- $zinc->translate($wp_group, -$zinc_width/2,-$zinc_height/2);
- $zinc->scale($wp_group,1.2,1.2);
- $zinc->translate($wp_group,$zinc_width/2,$zinc_height/2);
- })->pack(-side => 'right');
-
-
-
-MainLoop;
diff --git a/Perl/demos/Tk/demos/zinc_pm/SimpleRadarControls.pm b/Perl/demos/Tk/demos/zinc_pm/SimpleRadarControls.pm
deleted file mode 100644
index 723f3ec..0000000
--- a/Perl/demos/Tk/demos/zinc_pm/SimpleRadarControls.pm
+++ /dev/null
@@ -1,235 +0,0 @@
-package SimpleRadarControls;
-
-# $Id$
-# This simple radar has been initially developped by P. Lecoanet <lecoanet@cena.fr>
-# It has been adapted by C. Mertz <mertz@cena.fr> for demo purpose.
-# Thanks to Dunnigan,Jack [Edm]" <Jack.Dunnigan@EC.gc.ca> for a bug correction.
-
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-$top = 1;
-
-sub new {
- my $proto = shift;
- my $type = ref($proto) || $proto;
- my ($zinc) = @_;
- my $self = {};
-
- $self{'zinc'} = $zinc;
- $self{'cur_x'} = 0;
- $self{'cur_y'} = 0;
- $self{'cur_angle'} = 0;
- $self{'corner_x'} = 0;
- $self{'corner_y'} = 0;
-
- $self{'tlbbox'} = $zinc->add('group', $top,
- -sensitive => 0, -visible => 0,
- -tags => 'currentbbox');
- $zinc->add('rectangle', $self{'tlbbox'}, [-3, -3, +3, +3]);
- $self{'trbbox'} = $zinc->add('group', $top,
- -sensitive => 0, -visible => 0,
- -tags => 'currentbbox');
- $zinc->add('rectangle', $self{'trbbox'}, [-3, -3, +3, +3]);
- $self{'blbbox'} = $zinc->add('group', $top,
- -sensitive => 0, -visible => 0,
- -tags => 'currentbbox');
- $zinc->add('rectangle', $self{'blbbox'}, [-3, -3, +3, +3]);
- $self{'brbbox'} = $zinc->add('group', $top,
- -sensitive => 0, -visible => 0,
- -tags => 'currentbbox');
- $zinc->add('rectangle', $self{'brbbox'}, [-3, -3, +3, +3]);
- $zinc->add('rectangle', $top, [0, 0, 1, 1],
- -linecolor => 'red', -tags => 'lasso',
- -visible => 0, -sensitive => 0);
-
- $zinc->Tk::bind('<Shift-ButtonPress-1>', [\&start_lasso, $self]);
- $zinc->Tk::bind('<Shift-ButtonRelease-1>', [\&fin_lasso, $self]);
-
- $zinc->Tk::bind('<ButtonPress-2>', sub { my $ev = $zinc->XEvent();
- my @closest = $zinc->find('closest',
- $ev->x, $ev->y);
- print "at point=$closest[0]\n" });
-
- $zinc->Tk::bind('<ButtonPress-3>', [\&press, $self, \&motion]);
- $zinc->Tk::bind('<ButtonRelease-3>', [\&release, $self]);
-
- $zinc->Tk::bind('<Shift-ButtonPress-3>', [\&press, $self, \&zoom]);
- $zinc->Tk::bind('<Shift-ButtonRelease-3>', [\&release, $self]);
-
- $zinc->Tk::bind('<Control-ButtonPress-3>', [\&press, $self, \&rotate]);
- $zinc->Tk::bind('<Control-ButtonRelease-3>', [\&release, $self]);
-
- $zinc->Tk::bind('current', '<Enter>', [\&showbox, $self]);
- $zinc->Tk::bind('current', '<Leave>', [\&hidebox, $self]);
-
- bless ($self, $type);
- return $self;
-}
-
-#
-# Controls for the window transform.
-#
-sub press {
- my ($zinc, $self, $action) = @_;
- my $ev = $zinc->XEvent();
- my $lx = $ev->x;
- my $ly = $ev->y;
-
- $self->{'cur_x'} = $lx;
- $self->{'cur_y'} = $ly;
- $self->{'cur_angle'} = atan2($ly, $lx);
- $zinc->Tk::bind('<Motion>', [$action, $self]);
-}
-
-sub motion {
- my ($zinc, $self) = @_;
- my $ev = $zinc->XEvent();
- my $lx = $ev->x;
- my $ly = $ev->y;
- my @it;
- my @res;
-
- @it = $zinc->find('withtag', 'controls');
- if (scalar(@it) == 0) {
- return;
- }
- @res = $zinc->transform($it[0], [$lx, $ly, $self->{'cur_x'}, $self->{'cur_y'}]);
- $zinc->translate('controls', $res[0] - $res[2], $res[1] - $res[3]);
- $self->{'cur_x'} = $lx;
- $self->{'cur_y'} = $ly;
-}
-
-sub zoom {
- my ($zinc, $self) = @_;
- my $ev = $zinc->XEvent();
- my $lx = $ev->x;
- my $ly = $ev->y;
- my $maxx;
- my $maxy;
- my $sx;
- my $sy;
-
- if ($lx > $self->{'cur_x'}) {
- $maxx = $lx;
- } else {
- $maxx = $self->{'cur_x'};
- }
- if ($ly > $self->{'cur_y'}) {
- $maxy = $ly
- } else {
- $maxy = $self->{'cur_y'};
- }
- #avoid illegal division by zero
- return unless ($maxx && $maxy);
-
- $sx = 1.0 + ($lx - $self->{'cur_x'})/$maxx;
- $sy = 1.0 + ($ly - $self->{'cur_y'})/$maxy;
- $self->{'cur_x'} = $lx if ($lx>0); # avoid ZnTransfoDecompose :singular matrix
- $self->{'cur_y'} = $ly if ($ly>0); # error messages
- $zinc->scale('controls', $sx, $sy);
-# $main::scale *= $sx;
-# main::update_transform($zinc);
-}
-
-sub rotate {
- my ($zinc, $self) = @_;
- my $ev = $zinc->XEvent();
- my $lx = $ev->x;
- my $ly = $ev->y;
- my $langle;
-
- $langle = atan2($ly, $lx);
- $zinc->rotate('controls', -($langle - $self->{'cur_angle'}));
- $self->{'cur_angle'} = $langle;
-}
-
-sub release {
- my ($zinc, $self) = @_;
- $zinc->Tk::bind('<Motion>', '');
-}
-
-sub start_lasso {
- my ($zinc, $self) = @_;
- my $ev = $zinc->XEvent();
- my $lx = $ev->x;
- my $ly = $ev->y;
- my @coords;
-
- $self->{'cur_x'} = $lx;
- $self->{'cur_y'} = $ly;
- $self->{'corner_x'} = $lx;
- $self->{'corner_y'} = $ly;
- @coords = $zinc->transform($top, [$lx, $ly]);
- $zinc->coords('lasso', [$coords[0], $coords[1], $coords[0], $coords[1]]);
- $zinc->itemconfigure('lasso', -visible => 1);
- $zinc->raise('lasso');
- $zinc->Tk::bind('<Motion>', [\&lasso, $self]);
-}
-
-sub lasso {
- my ($zinc, $self) = @_;
- my $ev = $zinc->XEvent();
- my $lx = $ev->x;
- my $ly = $ev->y;
- my @coords;
-
- $self->{'corner_x'} = $lx;
- $self->{'corner_y'} = $ly;
- @coords = $zinc->transform($top, [$self->{'cur_x'}, $self->{'cur_y'}, $lx, $ly]);
- $zinc->coords('lasso', [$coords[0], $coords[1], $coords[2], $coords[3]]);
-}
-
-sub fin_lasso {
- my ($zinc, $self) = @_;
- my $enclosed;
- my $overlapping;
-
- $zinc->Tk::bind('<Motion>', '');
- $zinc->itemconfigure('lasso', -visible => 0);
- $enclosed = join(', ', $zinc->find('enclosed',
- $self->{'cur_x'}, $self->{'cur_y'},
- $self->{'corner_x'}, $self->{'corner_y'}));
- $overlapping = join(', ', $zinc->find('overlapping',
- $self->{'cur_x'}, $self->{'cur_y'},
- $self->{'corner_x'}, $self->{'corner_y'}));
- print "enclosed=$enclosed, overlapping=$overlapping\n";
-}
-
-sub showbox {
- my ($zinc, $self) = @_;
- my @coords;
- my @it;
-
- if (! $zinc->hastag('current', 'currentbbox')) {
- @it = $zinc->find('withtag', 'current');
- if (scalar(@it) == 0) {
- return;
- }
- @coords = $zinc->transform($top, $zinc->bbox('current'));
-
- $zinc->coords($self->{'tlbbox'}, [$coords[0], $coords[1]]);
- $zinc->coords($self->{'trbbox'}, [$coords[2], $coords[1]]);
- $zinc->coords($self->{'brbbox'}, [$coords[2], $coords[3]]);
- $zinc->coords($self->{'blbbox'}, [$coords[0], $coords[3]]);
- $zinc->itemconfigure('currentbbox', -visible => 1);
- }
-}
-
-sub hidebox {
- my ($zinc, $self) = @_;
- my $ev = $zinc->XEvent();
- my $lx = $ev->x;
- my $ly = $ev->y;
- my @next;
-
- @next = $zinc->find('closest', $lx, $ly);
- if ((scalar(@next) == 0) ||
- ! $zinc->hastag($next[0], 'currentbbox') ||
- $zinc->hastag('current', 'currentbbox')) {
- $zinc->itemconfigure('currentbbox', -visible => 0);
- }
-}
-
-